-
Notifications
You must be signed in to change notification settings - Fork 586
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
Warning about componentWillReceiveProps
in React's Strict Mode
#624
Comments
Now with React 16.9 it's even a non-strict mode warning ... |
Any update on this @moroshko ? |
Still very relevant, looking forward to updates |
Here's a PR that should take care of it: #681 |
Fixed in #681 |
@aberezkin this should not have been closed. It resolves #670, but not this one. A warning is still shown in React's strictmode:
|
Can someone work on this? |
…ieveProps in Autowhatever component
* Catch-up master branch to upstream tag 10.1.0 * updated .gitignore for IDE config * moroshko#624 Refactor to move code out of deprecated componentWillRecieveProps * moroshko#624 Refactor to move code out of deprecated componentWillRecieveProps in Autowhatever component
* updated .gitignore for IDE config * moroshko#624 Refactor to move code out of deprecated componentWillRecieveProps * moroshko#624 Refactor to move code out of deprecated componentWillRecieveProps in Autowhatever component
It doesn't fix this warning for strict mode. To fix this issue the implementation has to change to this lifecycle: https://reactjs.org/docs/react-component.html#static-getderivedstatefromprops. Links from the snippet below:
|
React's Strict Mode warns about "Unsafe lifecycle methods were found within a strict-mode tree".
react-autosuggest/src/Autosuggest.js
Lines 124 to 143 in d626cef
The text was updated successfully, but these errors were encountered: