-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
b-input changes v-model from null to empty string on blur #6078
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
Comments
@lucianobosco Can you create a minimal reproduction fo the issue on CodePen or CodeSanbox? |
@jackmu95 Hope it helps! |
@lucianobosco Can you please confirm that this CodeSanbox with the changes of the linked PR applied solves the issue: |
@jackmu95 thanks! This is working as expected. |
@lucianobosco Yeah :) |
Describe the bug
By hydrating a b-input v-model with a null value and blurring the input with no changes, the object property is changed from
null
to an empty string""
. This happens only the first time when the input is hydrated. If you hydrate it again with no page refresh, it works as expected.Steps to reproduce the bug
<b-input>
with anull
value for thev-model
null
to""
Expected behavior
The object property must still as
null
Versions
Libraries:
Environment:
Additional context
This is causing an issue with some 3rd party validators like vee-validate, where a
pristine
flag is set tofalse
because changes were detected on the object (fromnull
to""
).The text was updated successfully, but these errors were encountered: