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
I'm not sure if this is a feature or not, but I would expect that when a field is using an async validator and it hasn't finished yet, the form should not change its isValid state to true.
For example, this allows the form to be submitted before validation is complete.
I also tried setting defaultState: { isValid: false }, but it did not work as expected. Form always defaults to isValid: true
It also behaves weirdly when you click outside of the input while the field is currently validating.
Describe the bug
I'm not sure if this is a feature or not, but I would expect that when a field is using an async validator and it hasn't finished yet, the form should not change its
isValid
state totrue
.For example, this allows the form to be submitted before validation is complete.
defaultState: { isValid: false }
, but it did not work as expected. Form always defaults toisValid: true
Your minimal, reproducible example
https://stackblitz.com/edit/tanstack-form-tofchgxp?file=src%2Findex.tsx
Steps to reproduce
isValid:true
Expected behavior
I would expect that form will never change
isValid
until validator is doneHow often does this bug happen?
Every time
Screenshots or Videos
bug-report.mp4
Platform
Google chrome
TanStack Form adapter
react-form
TanStack Form version
0.41.3
TypeScript version
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: