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
If an input has onBlur set to field.handleBlur, but onBlur is not defined on a field or form level, the onBlur event (just clicking on an element and clicking away from it) makes the field valid even if nothing has changed.
Now click on the username field and click away from it
canSubmit and isFormValid will turn from false to true
Expected behavior
Just clicking on an input and outside of it should not change canSubmit to true
How often does this bug happen?
Every time
Screenshots or Videos
No response
Platform
Chrome (stackblitz)
Chrome (Windows 11)
TanStack Form adapter
None
TanStack Form version
0.41.1
TypeScript version
5.7.3
Additional context
I kind of noticed this by accident as I left the onBlur property in one of my inputs after copying one of the examples from the docs.
Technically not a 'real' bug as it comes from user mistake but still, it is not the correct behavior for onBlur to validate fields automatically if it is not defined.
The text was updated successfully, but these errors were encountered:
Describe the bug
If an input has onBlur set to field.handleBlur, but onBlur is not defined on a field or form level, the onBlur event (just clicking on an element and clicking away from it) makes the field valid even if nothing has changed.
Your minimal, reproducible example
https://stackblitz.com/edit/tanstack-form-ndou4jtx?file=src%2Findex.tsx
Steps to reproduce
Expected behavior
Just clicking on an input and outside of it should not change canSubmit to true
How often does this bug happen?
Every time
Screenshots or Videos
No response
Platform
TanStack Form adapter
None
TanStack Form version
0.41.1
TypeScript version
5.7.3
Additional context
I kind of noticed this by accident as I left the onBlur property in one of my inputs after copying one of the examples from the docs.
Technically not a 'real' bug as it comes from user mistake but still, it is not the correct behavior for onBlur to validate fields automatically if it is not defined.
The text was updated successfully, but these errors were encountered: