I'm currently utilizing the vuelidate library to validate my forms. I've been attempting to use the built-in validators along with a custom message, as shown below. However, I have encountered issues with it not functioning properly. For reference: Vuelidate Form validation library
validations() {
return {
email: {
requiredIf: requiredIf(() => {
return this.data.enablevalidation;
}),
email: helpers.withMessage(this.data.validation_err_message, email),
},
};
},
The problem I am facing is that even if the main validation fails, the email field is still being validated. Ideally, validation should only pass if both conditions are met. If the main validation fails, the email validation should also be skipped. How can I achieve this specific scenario?