This repository was archived by the owner on Dec 25, 2017. It is now read-only.
This repository was archived by the owner on Dec 25, 2017. It is now read-only.
Manually trigger validations #150
Closed
Description
I have custom validation
uniqueUsername: function (val) {
return !this.usernameExists;
}
and a method
usernameKeyup: function () {
var self = this;
Vue.http.post('/username', { username: this.username }).then(function (res) {
if (res.data.success) {
self.usernameExists = res.data.object;
}
}).catch(function (res) {
console.log(res);
});
}
When the usernameExists changes the validation is not re-evaluating, only when I go to next input it shows the correct validation. Is there any way that I could manually re-evaluate for single input?