VeeValidate async cross-field validation re-trigger behavior
0 reputation · 23 Mar 2024, 04:49 UTC
Cross-field async validation timing
When using useForm with async validation rules that reference other field values, the library does not specify whether a change in a dependency field should automatically re-trigger validation of the dependent field. The validation mode configuration controls when validation runs for the field being edited, but cross-field re-evaluation is not addressed in the documented trigger options.
Permission boundary ambiguity
There is no explicit boundary defining which fields may read or modify the validation state of others. Custom rules receive the full form context, allowing any rule to inspect any field value, yet the framework does not enforce a contract for when dependent validations must re-run or how duplicate async invocations are deduplicated.
Version-sensitive composable surface
Behavior differs between VeeValidate v4 and v5, particularly around composable names (useForm vs useField exports) and the shape of the returned meta and error refs. Assumptions about automatic re-validation timing may not hold across major versions.
What is the expected re-trigger behavior for async rules when a dependency field changes? Does the validation mode setting apply to cross-field re-evaluation? How should applications manage debounce and cancellation for dependent async validations without framework guidance?