Skip to content

.sync doesn't work with kebab case update events #8004

Closed
@zfeher

Description

@zfeher

Version

2.5.16

Reproduction link

https://jsfiddle.net/50wL7mdz/293614/

Steps to reproduce

Just run the attached fiddle and click on Change Bar button.

What is expected?

The foo prop in root component should be updated via .sync

What is actually happening?

The foo prop doesn't get updated.


We are currently migrating from Vue 1 to Vue 2 and we need to stick with using kebab case when naming component and event names. .sync seems useful and less boilerplate and I think it should work with both casing camel/kebab too.

Also I found the following in the docs at .sync Modifier: "That’s why instead, we recommend emitting events in the pattern of update:my-prop-name. " Which is kebab case but it doesn't work with sync.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions