Address "Unsafe lifecycle methods were found within a strict-mode tree" warnings
See original GitHub issueAny plans to replace componentWillReceiveProps
in the DatePicker
and Calendar
components as this lifecycle will be depracated in react
v16.4? react-lifecycles-compat is another option.
Issue Analytics
- State:
- Created 5 years ago
- Comments:10 (6 by maintainers)
Top Results From Across the Web
Unsafe lifecycle methods were found within a strict-mode tree ...
React's strict mode (flags deprecating APIs) throws warnings in development of using the componentWillReceiveProps method, and recommends ...
Read more >Strict Mode - React
As explained in this blog post, certain legacy lifecycle methods are unsafe for use in async React applications. However, if your application uses...
Read more >Using strict mode in React 18: A guide to its new behaviors
Introduction to React's strict mode; Warnings on the use of unsafe lifecycle methods; Recommending the createRef API over the legacy string ...
Read more >please update the following components: sideeffect(nullcomponent2 ...
Warning : Unsafe lifecycle methods were found within a strict-mode tree: componentWillMount: Please update the following components to use componentDidMount ...
Read more >“The editor has encountered an unexpected error ...
react-dom.js?ver=16.8.4:500 Warning: Unsafe lifecycle methods were found within a strict-mode tree: in StrictMode (created by Editor) in Editor (created by ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
To be clear,
componentWillMount
,componentWillReceiveProps
, andcomponentWillUpdate
are already deprecated in 16.3. They will continue to be supported until 17.0.Deprecation warnings will be enabled during some future release – not necessarily 16.4 AFAICT.
Anyway, we should plan to upgrade, but doing so will most likely involve dropping support for React <16.3.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.