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
Have a Popup component with hideOnScroll enabled, inside a view that can get unmounted at any time (for example in the contents of a view which changes its contents based on the selected tab)
Hover over the Popup
Without scrolling, change the view which the Popup lived (unmount it)
Scroll
Expected Result
I would expect the hanlePortalUnmount method of the Popup to remove the hideOnScroll method from the window's scroll event, when the Popup is unmounted. Code
Actual Result
The hideOnScroll is not removed from the window's scroll event, when the Popup is unmounted. As a result when I am in the new view and scroll, the hideOnScroll of the currently unmounted Popup will be executed and try to setState in a currently unmounted component, resulting in this error
warning.js:36 Warning: setState(...): Can only update a mounted or mounting component. This usually means you called setState() on an unmounted component. This is a no-op. Please check the code for the Popup component.
Version
Latest
The text was updated successfully, but these errors were encountered:
Steps
hideOnScroll
enabled, inside a view that can get unmounted at any time (for example in the contents of a view which changes its contents based on the selected tab)Expected Result
I would expect the
hanlePortalUnmount
method of the Popup to remove thehideOnScroll
method from thewindow
'sscroll
event, when the Popup is unmounted. CodeActual Result
The
hideOnScroll
is not removed from thewindow
'sscroll
event, when the Popup is unmounted. As a result when I am in the new view and scroll, thehideOnScroll
of the currently unmounted Popup will be executed and try tosetState
in a currently unmounted component, resulting in this errorVersion
Latest
The text was updated successfully, but these errors were encountered: