I am faced with a challenge on a page where I have a collection of user cards. Each card has specific field names that need to be differentiated using an index, such as userDob${i}
.
In addition, I need to generate custom messages for these user inputs. Normally, I can define custom messages like this:
custom: {
userDob: {
required: 'User dob is required',
date_format: 'Please enter a dob in the correct format (yyyy-mm-dd)'
},
}
However, in this scenario, I require a more dynamic approach. I need to find a way to disregard the index or assign an alias to use in my custom messaging instead of relying solely on the name attribute as the property name.
I thought Vee Validate had an option to use an alias, but I have been unable to locate it so far.