Relative Content

Tag Archive for vue.jsvee-validate

Vee-Validate V4 how do I create a custom error message in a function and get it displayed

I am new to vee-validate and using V4 with vue.
I have a text field that take in a string which I then use @change to call a function to validate the string. If the string is invalid, I want to set an error message and return and then display the resulting error message.
If the string is valid, I then issue a REST api call and the result may or may not be successful and if not, I want to set an error message and return. There will likely only be a single error message

Vee-validate – how to get all dirty fields

In my vue project I’m doing form validation with the help of vee-validate, primarily using useForm. One handy feature is the meta object, which has the dirty flag, indicating if any field has changed from its initial value.