juliancwirko / react-s-alert

Alerts / Notifications for React with rich configuration options
https://www.npmjs.com/package/react-s-alert
MIT License
649 stars 75 forks source link

fixes react StrictMode deprecation warnings #76

Open Nowheresly opened 5 years ago

Nowheresly commented 5 years ago

When using this library with the latest version of React with StrictMode enabled, two different warning are generated:

This PR just follows the official React documentation (here and here) to fix these warnings.

juliancwirko commented 5 years ago

Hi, thanks. But I think this version of library won't work with React 17 anyway. It have to be totally rewritten using new approaches in React introduced in newest versions.

And this needs more tests before publishing it.

Nowheresly commented 5 years ago

We can't be sure this library will work or not with React 17, but at least with this PR, there is no more any warnings.

As far as the tests are concerned, I was unable to run tests without error. It seems there is an already referenced issue about it (#54 ).

juliancwirko commented 5 years ago

Yes, I meant manual tests.