Skip to content

Camelcase all keys #4163

@lucaswoj

Description

@lucaswoj

From @lucaswoj on December 23, 2016 14:41

Working with Mapbox style spec objects in Javascript is less ergonomic because all the dashcase properties must be quoted when they are used as identifiers.

var layer = { 'line-color': 'blue' }
layer['line-color']

vs

var layer = { lineColor: 'blue' }
layer.lineColor

They look odd in conjunction with the camelcased source properties #175

Copied from original issue: mapbox/mapbox-gl-style-spec#638

Metadata

Metadata

Assignees

No one assigned

    Labels

    breaking change ⚠️Requires a backwards-incompatible change to the APIcross-platform 📺Requires coordination with Mapbox GL Native (style specification, rendering tests, etc.)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions