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
I recently upgraded from version 2.0.9 to 2.1.7 and had to change the definition of a v-model in a v-for loop to get it working in 2.1.7. Maybe this is a bug.
Sorry for the long response, due to implementation changes to the directive. The v-for loops had a lot of issues with the model detection, I will try to explain them briefly here:
Internally vee-validate directive uses $watch to detect changes to inputs bound with v-model, using the same expression passed to the model as the watch arg. That wouldn't work since customers.firstName only exists inside the loop context, so vee-validate cannot find the model and thus cannot detect its changes.
I suggest you take a look at ValidationProviders as they are the new way to use vee-validate and provide greater flexibility and do not have the same limitations as the directive.
Versions
I recently upgraded from version 2.0.9 to 2.1.7 and had to change the definition of a v-model in a v-for loop to get it working in 2.1.7. Maybe this is a bug.
In 2.0.9 this was working fine:
In 2.1.7 i had to change it to:
If i use customer.firstName the field is not validated and the errorbag is not updated on input changes.
The text was updated successfully, but these errors were encountered: