Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] <Field> slot prop handleBlur() documentation does not match code behavior #4285

Closed
3 of 5 tasks
ghost opened this issue May 23, 2023 · 1 comment
Closed
3 of 5 tasks
Labels
🐛 bug Unintended behavior

Comments

@ghost
Copy link

ghost commented May 23, 2023

What happened?

Regarding the <Field> slot props:

  • field.onBlur does respect validateOnBlur
  • handleBlur does not respect validateOnBlur (won't validate at all) even though the documentation indicates that it should

Reproduction steps

  1. Write a custom input component and pass it as a slot to <Field>
  2. Expose the slot prop handleBlur: <Field v-slot="{ handleBlur }" ... />
  3. Bind the handleBlur to your nested custom input component <CustomInputComponent @blur="handleBlur" .../>
  4. Observe that blurring your CustomInputComponent will not trigger validation no matter if validateOnBlur is true or false

Version

Vue.js 3.x and vee-validate 4.x

What browsers are you seeing the problem on?

  • Firefox
  • Chrome
  • Safari
  • Microsoft Edge

Relevant log output

No response

Demo link

The bug is obvious enough in the code/documentation

Code of Conduct

@logaretm logaretm added the 🐛 bug Unintended behavior label May 24, 2023
@logaretm
Copy link
Owner

Thanks for reporting this, should be fixed with the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Unintended behavior
Projects
None yet
Development

No branches or pull requests

1 participant