You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The node passed in overlay prop to OverlayTrigger is rendered all the time. Which doesn't make sense. Real life example: if there's a notification icon in the header which triggers the notification popup to be shown (similarly to facebook) and there's an error in the popover the whole application will crash. Moreover it needs more resource to render that mostly not opened component.
So we shouldn't render the overlay element until the state becomes active.
Maybe to prevent breaking changes and there can be others who rely on this sideeffect, it would be wise to introduce a lazyRender prop and if that's true we should postpone all the rendering as we can. But performance wise and being mobile friendly I would definately make the lazyrendering default.
The text was updated successfully, but these errors were encountered:
The node passed in overlay prop to
OverlayTrigger
is rendered all the time. Which doesn't make sense. Real life example: if there's a notification icon in the header which triggers the notification popup to be shown (similarly to facebook) and there's an error in the popover the whole application will crash. Moreover it needs more resource to render that mostly not opened component.So we shouldn't render the overlay element until the state becomes active.
Basically
The code where this should be added is here:
intellyo-application-design-system/src/components/overlay-trigger/index.js
Lines 126 to 135 in 2ea245e
Maybe to prevent breaking changes and there can be others who rely on this sideeffect, it would be wise to introduce a
lazyRender
prop and if that's true we should postpone all the rendering as we can. But performance wise and being mobile friendly I would definately make the lazyrendering default.The text was updated successfully, but these errors were encountered: