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
{{ message }}
Repository navigation
Warning : componentWillReceiveProps has been renamed, and is not recommended for use. #3745
I am getting this warning in console. I have installed the latest version ^3.0.4 of react-select along with ^3.0.4 of @types/react-select. The warning says that - Please update the following components: AutosizeInput, Select. I tried looking for componentWillReceiveProps method in the repo, but I couldn't find any file using it. Why am I getting this warning?
Reacted by Alessio Di Crescenzo, Roman May, Sebastian "Sebbie" Silbermann, Sander, Andreas, Kiran Kalyan, yamagen0915, Wait4Code, Constantin Pojoga, Indra Susila and 15 more
the same warning message is happening for jest as well.
`console.warn node_modules/react-dom/cjs/react-dom.development.js:11494
Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details.
* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.
Please update the following components: AutosizeInput, Select
Still getting warning messages as of 3.0.8. This will prevent the new react concurrent mode (not released yet) from working.
To reproduce, wrap your app in <React.StrictMode></React.StrictMode> tags.
Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details.
* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
Please update the following components: AutosizeInput, Select
Reacted by Drew Terry, Immo Sanders-Sjuts, Maurice Dalderup, Glenn 'devalias' Grant and Anecha Kuekharem
Still getting warning messages as of 3.0.8. This will prevent the new react concurrent mode (not released yet) from working.
To reproduce, wrap your app in <React.StrictMode></React.StrictMode> tags.
Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://fb.me/react-unsafe-component-lifecycles for details.
* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
Please update the following components: AutosizeInput, Select
Same for me, wrapping it in StrictMode it is filled with warning.
See my reply here for the exact warnings: #3751 (comment)
Thank you to everyone who has provided information above.
As you may be aware, this bug has been reported multiple times as per issue #4094. On behalf of the maintainers I apologise it's taken awhile to get to this.
A new master issue #4094 has since been created to help keep track of this bug going forward.
This new issue will exist as the source of truth going forward to investigate the issue, report findings, and implement a bug fix.
We'll take into account all the details above while investigating.
If you feel this issue has been wrongly closed as it isn't related to the new master issue #4094, please let us know and we'll take another look.
Activity
dicrescenzoa commentedon Aug 30, 2019
the same warning message is happening for jest as well.
`console.warn node_modules/react-dom/cjs/react-dom.development.js:11494
Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details.
`
package.json
jarleriksen commentedon Aug 31, 2019
Check #3720
mreishus commentedon Oct 24, 2019
Still getting warning messages as of 3.0.8. This will prevent the new react concurrent mode (not released yet) from working.
To reproduce, wrap your app in
<React.StrictMode></React.StrictMode>tags.DalderupMaurice commentedon Jan 3, 2020
Same for me, wrapping it in StrictMode it is filled with warning.
See my reply here for the exact warnings: #3751 (comment)
makker commentedon Apr 21, 2020
+1
0xdevalias commentedon Apr 22, 2020
See also:
#3720 (comment)
bladey commentedon Jun 18, 2020
Hi all,
Thank you to everyone who has provided information above.
As you may be aware, this bug has been reported multiple times as per issue #4094. On behalf of the maintainers I apologise it's taken awhile to get to this.
A new master issue #4094 has since been created to help keep track of this bug going forward.
This new issue will exist as the source of truth going forward to investigate the issue, report findings, and implement a bug fix.
We'll take into account all the details above while investigating.
If you feel this issue has been wrongly closed as it isn't related to the new master issue #4094, please let us know and we'll take another look.
Again, thank you.