Closed grgr-dkrk closed 3 years ago
Thanks, I think this is currently being worked on in https://github.com/davidtheclark/react-aria-modal/pull/95! Hopefully it will be merged soon.
This issue is two years old now and has not actually been fixed yet by #95 (also about 2 years old) or #108 (almost a year old). The warning alone clutters up consoles and test suites. I am simply commenting to vouch for something to be done about this.
Fixed at #121
The
componentWillMount
method is deprecated since React 16.3, and it will be removed in React 17. (we will now see a warning when using it in 16.9)It's necessary to use the
constructor
orcomponentDidMount
method instead ofcomponentWillMount
.We can also use the
UNSAFE_componentWillMount
but it's not needed in this case I think.https://github.com/davidtheclark/react-aria-modal/blob/d19442e97e3e3565381723c85b197b8de0df364a/src/react-aria-modal.js#L18-L24
react-displace
has the same problems, and needs fix to both.Please check this PR: https://github.com/davidtheclark/react-displace/pull/8