captivationsoftware / react-sticky

<Sticky /> component for awesome React apps
MIT License
2.64k stars 388 forks source link

Update "componentWillMount" to "componentDidMount" #326

Open slafleche opened 2 years ago

slafleche commented 2 years ago

React is complaining about the use of componentWillMount.

Warning: componentWillMount has been renamed, and is not recommended for use. See https://reactjs.org/link/unsafe-component-lifecycles for details.

* Move code from componentWillMount to componentDidMount (preferred in most cases) or the constructor.

Please update the following components: Sticky
pranahonk commented 2 years ago

i have the same issue

frsnmk commented 2 years ago

me too

arnm commented 1 year ago

Just to clarify this is when using React 18. When using React 17 I do not see this issue

carlosbaraza commented 1 year ago

This is a React 18 issue @arnm

seangibeault commented 2 months ago

bump