boring-avatars icon indicating copy to clipboard operation
boring-avatars copied to clipboard

TypeError: n.useId is not a function

Open Zahnstochermann opened this issue 2 years ago • 2 comments

Describe the bug Page crashes with the error: "TypeError: n.useId is not a function"

To Reproduce

  1. install boring-avatars via npm
  2. use basic example from readme in a react component

Expected behavior No error.

Screenshots image

Desktop:

  • OS: Windows 11
  • Browser: Chrome (v 120)
  • React 17.0.2

Zahnstochermann avatar Jan 19 '24 11:01 Zahnstochermann

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Feb 18 '24 20:02 github-actions[bot]

Having the same issue here. Took me days to figure out why my app was breaking 😆 Thanks for flagging this! Will use a different plugin 💨

robbieredfearn-dpm avatar Feb 21 '24 16:02 robbieredfearn-dpm

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days.

github-actions[bot] avatar Mar 22 '24 20:03 github-actions[bot]

Hey, the useId() hook is only available in React 18 or above versions.

If you can't upgrade your project to the latest React version, I'd recommend using the v1.7.0 boring-avatars version: https://www.npmjs.com/package/boring-avatars/v/1.7.0

Hope that works

josepmartins avatar Apr 09 '24 14:04 josepmartins