react-autosuggest: Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended

In a new React app running version 17.0.2, I get a console error when using this component:

Warning: Using UNSAFE_componentWillReceiveProps in strict mode is not recommended and may indicate bugs in your code. See https://reactjs.org/link/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://reactjs.org/link/derived-state

Please update the following components: Autosuggest, Autowhatever

About this issue

  • Original URL
  • State: open
  • Created 3 years ago
  • Reactions: 31
  • Comments: 16

Most upvoted comments

It seems that the problem is React strict mode, I currently work with version 18.2. So when you comment or delete the warning no longer appears: Code_2hKHMXRV4y

This package is not being maintained anymore. This is also a very old issue #624 .

2022, this problem is still actual 😦

This issue was opened in Dec 2021, the last commit was in Jan 2021 (one year before this issue was created). I don’t think that this will be solved, looks like this project is dead 😦