fkhadra / react-toastify

React notification made easy 🚀 !
https://fkhadra.github.io/react-toastify/introduction
MIT License
12.33k stars 676 forks source link

Warning: ToastContainer: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead. #970

Closed marquesm91 closed 5 months ago

marquesm91 commented 1 year ago

Do you want to request a feature or report a bug? feature

What is the current behavior? When I am trying to use react-toastify with react@18.2.0 I am getting this warning. The React MR to print this warning on console is here.

I am pretty sure this is a small refactor to remove this warning and I could work on that 😄

Captura de Tela 2023-06-07 às 14 36 20

Warning: ToastContainer: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.

What is the expected behavior? No warning should appear

Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?

React 18.2

fkhadra commented 1 year ago

Hey this is addressed in v10, I'm currently working on it

maiveasna24 commented 7 months ago

got this issues in next-js version 14

rwb196884 commented 1 month ago

Still broken in 10.0.5