moroshko/react-autosuggest

Warning about `componentWillReceiveProps` in React's Strict Mode

Open

#624 aperta il 16 mar 2019

Vedi su GitHub
 (9 commenti) (54 reazioni) (0 assegnatari)JavaScript (637 fork)batch import
help wanted

Metriche repository

Star
 (5936 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

React's Strict Mode warns about "Unsafe lifecycle methods were found within a strict-mode tree".

componentWillReceiveProps: Please update the following components to use static getDerivedStateFromProps instead.

https://github.com/moroshko/react-autosuggest/blob/d626cef720df0ed5a4c7df4d539836b86bda6afa/src/Autosuggest.js#L124-L143

Guida contributor