adexin / spinners-react

Lightweight SVG/CSS spinners for React
https://adexin.github.io/spinners/
MIT License
405 stars 20 forks source link

defaultProps getting removed from React 18.3 #22

Open rafma0 opened 1 year ago

rafma0 commented 1 year ago

Hi,

Recently the console started displaying a message about defaultProps being removed in the next major React release and it needs to to be updated

Warning: Wrapper: Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.
  at Wrapper (webpack-internal:///(app-client)/./node_modules/spinners-react/lib/esm/withSharedProps-a1728349.js:60:27)

Thank you :)

benderillo commented 1 year ago

Same here. While working on NextJS 13 I am having this warnings from React dev tools.

baba43 commented 1 year ago

Thank you very much for providing this library. I also have the same issue.

hasaansworld commented 5 months ago

This library is awesome, can you please switch from default props to default parameters?

DrZanuff commented 5 months ago

Hi, i've created a PR trying to address this issue: https://github.com/adexin/spinners-react/pull/23