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: setValue on nested v-model do not correctly update parent #2468

Open
tharvik opened this issue Jul 9, 2024 · 0 comments
Open

Bug: setValue on nested v-model do not correctly update parent #2468

tharvik opened this issue Jul 9, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@tharvik
Copy link

tharvik commented Jul 9, 2024

Describe the bug
with nested v-model components, updating the child doesn't propagate changes to the parents, only the direct one.

To Reproduce
I setup a PR with a test triggering it. the normal vue behavior can be testing in this playground

Expected behavior
in nested v-model, if the child changes, it should update all it's depending parents, as vue does.

Related information:
it look like that setValue replace the ref of a model by the value directly. it should update the ref instead.

Additional context
I was able to workaround it by replacing in my test stack

comp.setValue("value");

by

comp.vm.modelValue.value = "value";

EDIT: workaround is not working for deeper hierarchy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant