Support for React 18
GrossDesignCo opened this issue · 3 comments
Hey there, React 18 came out this week, and react-uid is on my list of dependencies that need to add support before I can upgrade.
It doesn't look like there are any obvious breaking changes that would affect react-uid, so adding support should be as simple as updating the peerDependencies.
Happy to PR the fix if I can get permissions :)
Some functionality provided by this library is no longer server-side friendly if you use Concurrent or Strict modes, and thus for React 18 one should prefer a new useId
hook.
We are looking for ways to discourage using useUID
for ServerSide environment and deprecate it for all React 18 users.
This is the second like of the current readme
PS: Adding peer deps in any case....
Good to know, I saw useId
in the release notes, but will dig into it deeper. I do need to support React 16/17/18, so I'd like to still include this package, and just not get the peerDeps error. Ideally I can use useId
if React 18 is installed & fall back to useUID
if it's on a lower version.
TY!
The update was issues as 2.3.2