LePatron.email icon indicating copy to clipboard operation
LePatron.email copied to clipboard

Improve Form components

Open FabienEssid opened this issue 3 years ago • 0 comments

We would like to improve our form components to have a better development experience and to optimize the code.
I think we could do some research for those things :

  • [ ] Create a "sub" v-text-field component for example which take a prop to remove the following lines :
@input="$v.scope.field.$touch()"
@blur=$v.scope.field.$touch()"
  • [ ] Create a mixin to put some code inside it and to remove this code in components. For example :
  • requiredErrors method
  • isValidForm, a new method to remove the following lines in onSubmit methods :
this.$v.$touch();
if (this.$v.$invalid) return;

FabienEssid avatar Mar 01 '21 14:03 FabienEssid