You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expected behavior
Only reset flags that are related to the validation state.
Current Workaround
Hacky, but works...
// bugfix: required flag is removed on resetValidationProvider.mixin({created(this: InstanceType<typeofValidationProvider>){this.reset=((orig: ()=>void)=>{return()=>{orig.call(this);// Trigger the watcherconstforceRequired=this.forceRequired;this.forceRequired=!forceRequired;this.forceRequired=forceRequired;// set the flagconsttriggerRequireFlag=this.isRequired;};})(this.reset);},});
The text was updated successfully, but these errors were encountered:
Versions
Describe the bug
If you call reset() on a ValidationProvider, a possible "required" flag is removed.
vee-validate/src/components/Provider.ts
Lines 198 to 204 in af3ac11
Here a new default flags object is created but the required flag is not set again.
To reproduce
Go to https://codesandbox.io/s/vue-template-0vcyi and click the reset button in the example. The asterisk is removed.
Expected behavior
Only reset flags that are related to the validation state.
Current Workaround
Hacky, but works...
The text was updated successfully, but these errors were encountered: