Fixing docs in response to react-map-gl named export change #9427
+6
−6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Background
I was working with deck.gl for the first time and wasn't able to get the "getting started" example working. Turns out the latest version of react-map-gl (
8.x
) doesn't export anything from"."
you have to use'react-map-gl/{'mapbox' | 'maplibre' | mapbox-legacy'}
etc.Reproduction instructions
react-map-gl 8.0.1
try to implement the deck.gl react example using usingimport Map from 'react-map-gl'
Internal server error: Failed to resolve entry for package "react-map-gl". The package may have incorrect main/module/exports specified in its package.json: Missing "." specifier in "react-map-gl" package
Additional Context
If you look in
node_modules
the package.json ofreact-map-gl
contains the following:Change List