Replies: 1 comment
-
|
mapbox/maplibre do not load under node. You may be able to get them to load with JSDOM mocking all the browser global objects, or you can look into something like https://github.com/mapbox/mapbox-gl-js-mock |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have this component where when the user selects a position on the map an
h3tag appears informing the user they have selected said position:I'm just wandering how do you correctly mock the
Mapcomponent provided byreact-map-gl?This is my unit test so far:
I think I'm not mocking
react-map-glbut I've tried so many things I honestly don't know what I'm doing wrong.Does anyone know how to mock it correctly?
Beta Was this translation helpful? Give feedback.
All reactions