2π
β
If you donβt want to use arrow function, you can just pass a normal function in its place as:
VeeValidate.Validator.extend('verify_username', {
getMessage: function (field) {
return "username must be..."
},
validate: function (value) {
return "[...]"
}
});
These functions are identical:
(foo) => 'bar';
is the same as:
function (foo) {
return 'bar'
}
π€samayo
Source:stackexchange.com