-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LeftNav componentWillReceiveProps open-state conflict #2158
Comments
I'm also having this problem. The related code change is #2044. I'm calling leftNav.close() and then routing my app causing a re-render. When |
Sounds like we can do an easy fix. Do you want to give a try? |
If you don't want to change the API to use props.open, this should fix the bug. Pull Request |
I think that It will be better to remove this imperative |
@subjectix yes, it's working now. |
For me, the componentWillReceiveProps callback is setting state.open to true before the call to setState({open: false}) inside of the close function has had time to take effect, preventing the menu from closing when the close or toggle methods are called. I've commented out the line to set state.open inside of component will receive props as as workaround. To fix this, I think that state.open should only be set inside of componentWillReceiveProps if props.docked !== nextProps.docked.
The text was updated successfully, but these errors were encountered: