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
[Doc] Clarify future roadmaps regarding react-map-gl v7 APIs #8147
Comments
The page you linked already contains paragraphs that explain what you need to do to use map controls depending on your react-map-gl version. Feel free to suggest a change if it's not clear to you.
We do our best to make the integration painless, but it is never a goal for one library to support "all features" of another. You are only focusing on the control components, but there are a lot more features there that are incompatible, such as non-mercator projection, terrain, etc. Most of them are unsupported not by choice, but by how much API mapbox/maplibre opens to third-party developers.
The decision to drop support for deck.gl's deck.gl does not "recommend" a particular react-map-gl version over another. To make that decision, it's best for you to consult the react-map-gl documentation. deck.gl will offer its own set of UI components that are independent from any base map library. The work is tracked by this issue. Whether you want to wait for that feature depends on what controls you are trying to use. If you need controls that are Mapbox-specific, such as directions, then this effort will not help you.
I'm not sure I understand the question. |
Sorry, this question was not very relevant (I was under the impression that the different control implementations from mapboxv2/mapboxv1/maplibre might affect compatibility with the deck control or layer but since it all goes through standard react-map-gl APIs it makes no difference obviously. Also I didn't take time to just simply code and verify this) By the way I also noticed that in #7641 you switched almost all getting-started examples to maplibre, which I find very nice and reassuring, it gives a strong sense of support to the maplibre setup which is awesome. It goes well with the sentence "If the forked libraries and Mapbox API diverge in the future, compatibility issues may arise. deck.gl intends to support open source efforts wherever reasonable. Please report any issue on GitHub." from https://deck.gl/docs/developer-guide/base-maps/using-with-mapbox#compatibility-with-mapbox-gl-js-forks |
Thank you for your answer, I'll be following #7946 closely ! As for the docs, I'm happy to help if I can because this is an awesome project. Here are my thoughts: As a user, I find it confusing that what is documented as "basic functionality" for maps (see https://deck.gl/docs/api-reference/mapbox/overview#using-mapbox-gl-controls-with-deckgl, "The Mapbox ecosystem offers many well-designed controls, from the basic functionalities of NavigationControl [...]") is not working with what feels like should be the recommended setup: latest versions of everything, and using the most "tested and robust" use cases. I think I understand a little bit more why I was confused. I think it comes down to information order and implicit information I perceived when reading the docs:
Additionally, while it's nice to have docs that showcase the most advanced multiview/nonmercator/terrain features of deckgl in other pages, I think the https://deck.gl/docs/developer-guide/base-maps/using-with-mapbox page should prioritize the basic use case of a simple map using the latest versions of everything with navigation controls and a deckgl overlay. As a side note it feels like the root problem is that react-map-gl v7 forcibly took control of the user input and camera away from deck.gl, and that this is unfortunate from the point of view of deckgl (So much for being a nice companion module...). I think explaining this in the docs would also help greatly to clarify things. But this means that deckgl does have to take a standpoint regarding the react-map-gl version (contrary to what you said "deck.gl does not "recommend" a particular react-map-gl version over another." So I see a lot of different improvements ideas, maybe I can put them all in #8146 and you can choose the ones that you like ? |
So I just spent a few hours thinking about this and rewording the docs, I think the changes from #8146 shows how opinionated the previous version was and apply the same techniques to push in the exact opposite direction. Let me know what you think. |
Thank you for your help on the docs. I've taken feedback into account and updated them, so I'm closing this now. Feel free to send comments if have more feedback! |
Link
#7129
Description
Should https://deck.gl/docs/developer-guide/base-maps/using-with-mapbox#react-map-gl
recommend MapBoxOverlay first instead of Root Deck first because MapBoxOverlay allows to use all the features of the latest react-map-gl version (controls, which can be argued to be basic functionality of map) and has been used for a while now ?
note: Not sure about react-map-gl with maplibre or mapbox 1? does it work transparently ?
To decide this, a bit of context about how long and why there's this apparent paradox between the most robust form of using deck not supporting all features of recent react-map-gl versions ? Is this temporary ? Should everyone rewrite their code (and accept the new runtime behaviors) to use MapboxOverlay? Or will it be obsolete with react-map-gl 8 or deckgl 9 or something else and we just have to wait ? It's hard to know from a user point of view.
The text was updated successfully, but these errors were encountered: