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
Are you submitting a bug report or a feature request?
Bug
What is the current behavior?
Imagine we have a field with a field-level validation and an async blur validation : when a field-level validation update the error status, the async validation is not called. It could be good only if the update made by the field-level validation have found an error, not when the error is removed !
What is the expected behavior?
Async blur validation should be called if Field-level validation does not detect an error.
Example : type 'paul' in username field. At the end, blur is triggered but in redux devtools, we only saw action @@redux-form/UPDATE_SYNC_ERRORS and not @@redux-form/START_ASYNC_VALIDATION
Why ? Because, if the username length is not equal to 4, there's an error. So the first type you type p, the error invalid length is updated in store form.fieldLevelValidation.syncErrors.username. When you type a and u, the state does not change and after that, when you type l, the state is updated and set the error in form.fieldLevelValidation.syncErrors.username to null. And it seems that this behavior blocks the async blur validation because a change is done.
What's your environment?
Latest redux-form 8.2.6
The text was updated successfully, but these errors were encountered:
Are you submitting a bug report or a feature request?
Bug
What is the current behavior?
Imagine we have a field with a field-level validation and an async blur validation : when a field-level validation update the error status, the async validation is not called. It could be good only if the update made by the field-level validation have found an error, not when the error is removed !
What is the expected behavior?
Async blur validation should be called if Field-level validation does not detect an error.
Sandbox Link
https://codesandbox.io/embed/redux-form-template-5961u
Example : type 'paul' in username field. At the end, blur is triggered but in redux devtools, we only saw action
@@redux-form/UPDATE_SYNC_ERRORS
and not@@redux-form/START_ASYNC_VALIDATION
Why ? Because, if the username length is not equal to 4, there's an error. So the first type you type
p
, the errorinvalid length
is updated in storeform.fieldLevelValidation.syncErrors.username
. When you typea
andu
, the state does not change and after that, when you typel
, the state is updated and set the error inform.fieldLevelValidation.syncErrors.username
to null. And it seems that this behavior blocks the async blur validation because a change is done.What's your environment?
Latest redux-form 8.2.6
The text was updated successfully, but these errors were encountered: