You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Warning: Styled(button): Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.
#201
Closed
bonkrat opened this issue
Oct 5, 2023
· 1 comment
· Fixed by #211
Warning: Styled(button): Support for defaultProps will be removed from function components in a future major release. Use JavaScript default parameters instead.
I believe the recommended way to set default props now is to use JS destructuring and default values, something like this may work for the Button component:
This error is printing in the logs:
defaultProps
is being deprecated by React: facebook/react#25699I believe this is the culprit,
devtools/src/styled.tsx
Line 26 in 34e2e2e
I believe the recommended way to set default props now is to use JS destructuring and default values, something like this may work for the
Button
component:The text was updated successfully, but these errors were encountered: