Skip to content

Object keys which include dashes #3283

@bananatron

Description

@bananatron

Not sure if I'm missing something here, but I couldn't find anything in the docs or googling around.

Vue.js version

1.0.26

Reproduction Link

http://codepen.io/spenser/pen/AXxQyG?editors=1011

Steps to reproduce

Try to set an object property (which isn't previously defined) with a key beginning with a dash.

What is Expected?

It's expected that it would work like any other string.

What is actually happening?

Nothing is set. This is problematic specifically when dealing with Firebase, where when you push data, the keys coming back predominantly start with dashes and you'd ideally like to keep both Vue and your data store in sync (from what I've seen of Vuefire, it assumes your paths are static, and you aren't appending to objects in your store). I understand foreign characters that don't work as default property names might be problematic, but I'm just throwing this out there in case there's another solution.

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