Skip to content

Conversation

@nekosaur
Copy link
Contributor

@nekosaur nekosaur commented Mar 13, 2021

reverts changes made in #393. two way syncing can be done using the following code

const wrapper = mount(component, {
  props: {
    modelValue: 1,
    'onUpdate:modelValue': async (modelValue: number) => await wrapper.setProps({ modelValue })
  }
})

discussion regarding potential additional mount option for v-model usage continues in #279

closes #440

@nekosaur nekosaur force-pushed the fix/two-way-props branch from 5246e19 to dd3e1c9 Compare March 13, 2021 10:26
@lmiller1990
Copy link
Member

Thanks! I'll think about v-model a little more but won't delay the next release of this too much.

@lmiller1990 lmiller1990 merged commit 59cb210 into vuejs:master Mar 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Emitting v-model event leads to unexpectedly updated prop value

2 participants