gilbarbara / react-floater

Advanced tooltips for React
https://codesandbox.io/s/github/gilbarbara/react-floater/tree/main/demo
MIT License
220 stars 37 forks source link

defaultProps Deprecation #107

Closed leafkrober closed 1 month ago

leafkrober commented 4 months ago

🐛 Bug Report

Console errors when using react-floater

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

image

To Reproduce

Render a floater and observe the console (note: this may only appear on react 18+)

Expected behavior

No console errors or messages about defaultProps deprecation

Run npx envinfo --system --binaries --npmPackages react-floater

  System:
    OS: macOS 14.5
    CPU: (10) arm64 Apple M1 Max
    Memory: 1.17 GB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.13.1 - ~/.nvm/versions/node/v20.13.1/bin/node
    npm: 10.5.2 - ~/.nvm/versions/node/v20.13.1/bin/npm
    pnpm: 9.1.1 - ~/.nvm/versions/node/v20.13.1/bin/pnpm
    bun: 1.1.12 - /opt/homebrew/bin/bun
gilbarbara commented 4 months ago

Hey @leafkrober

Which react version are you using?

reergymerej commented 2 months ago

same - react@18.3