logaretm / vee-validate

✅ Painless Vue forms
https://vee-validate.logaretm.com/v4
MIT License
10.79k stars 1.26k forks source link

Vee validate 2.0 - how to set a field as dirty #2238

Closed Mikilll94 closed 5 years ago

Mikilll94 commented 5 years ago

Hello, How to set programatically a single field as dirty in vee-validate 2.0 in order to run validation? I don't see anything about that in the docs.

logaretm commented 5 years ago

In 2.0 you could do this:

This is referenced in the API docs: http://vee-validate.logaretm.com/v2/api/field.html#api

const field = this.$validator.fields.find({ name: 'email' });

field.setFlags({ dirty: true });
danieltorscho commented 9 months ago

How to change a dirty mode manually in v4 ? I can't find related documentation