Skip to content

Validation when mount the component #3922

Answered by logaretm
Ellathet asked this question in Q&A
Discussion options

You must be logged in to vote

At the moment useFieldModel doesn't respect any configuration because it does not represent fields. Just value paths, so vee-validate then must report the field errors at all times because it lacks any other signals like touched which is important for deciding when a field value should change.

This is why useField has validation triggers while useFieldModel does not.

I'm still figuring out how to work the useFieldModel API to be less confusing, especially in comparison to useField. So expect this behavior to be changed soon.

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
1 reply
@Ellathet
Comment options

Answer selected by Ellathet
Comment options

You must be logged in to vote
2 replies
@Ellathet
Comment options

@gaoyusongcn
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants