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

Refactor Map, introducing Style and Camera as public APIs #7070

Open
jfirebaugh opened this issue Aug 1, 2018 · 0 comments
Open

Refactor Map, introducing Style and Camera as public APIs #7070

jfirebaugh opened this issue Aug 1, 2018 · 0 comments
Labels
api 📝 breaking change ⚠️ Requires a backwards-incompatible change to the API GL native → GL JS For feature parity with Mapbox Maps SDK on a native platform

Comments

@jfirebaugh
Copy link
Contributor

In the current Mapbox GL JS API, almost the entirety of the API surface area lives on Map, making it a God object.

In particular, it isn't possible to manipulate a style via the runtime styling API, or a camera via the camera API, without either being associated with a live-rendering map. Separating Style and Camera classes from Map would improve Mapbox GL JS's internal architecture and make the external API more flexible. For example, a map-independent Camera would be a natural way to implement Map-independent projection/unprojection. In addition, it would bring GL JS closer to Native, which has public Style and Layer classes (though not Camera, yet).

This is a continuation/reframing of #2741.

@jfirebaugh jfirebaugh added GL native → GL JS For feature parity with Mapbox Maps SDK on a native platform breaking change ⚠️ Requires a backwards-incompatible change to the API api 📝 labels Aug 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api 📝 breaking change ⚠️ Requires a backwards-incompatible change to the API GL native → GL JS For feature parity with Mapbox Maps SDK on a native platform
Projects
None yet
Development

No branches or pull requests

1 participant