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
{{ message }}
Repository navigation
TypeError: useId is not a function - @tanstack/react-form not compatible with React 17 anymore #1829
TanStack Form declares support for React 17 in its peer dependencies, but now uses useId() which is only available in React 18+.
This causes a runtime error when using the library with React 17.
Error Message
TypeError: (0 , import_react3.useId) is not a function
OR export 'useId' (imported as 'useId') was not found in 'react'
Install @tanstack/react-form in a React 17 project
Use useForm() hook in a component
Run the application
Error occurs because useId is not defined was not found in react
Expected behavior
Either:
The library should work with React 17 as declared in peer dependencies
Or the peer dependencies should be updated to require React 18+
How often does this bug happen?
Every time
Screenshots or Videos
No response
Platform
OS: [macOS]
Browser: [Chrome]
TanStack Form adapter
None
TanStack Form version
1.23.8
TypeScript version
5.9.2
Additional context
No response
Reacted by Jacques Latrive, Lucas Charvolin and filoupegase
Activity
LeCarbonator commentedon Oct 30, 2025
Good catch - Looks to be a regression from
react-form@1.23.8onwards.