mapbox / mapbox-gl-leaflet

binding from Mapbox GL JS to the Leaflet API
ISC License
522 stars 154 forks source link

Map keeps shaking with percentage sizes #150

Closed Jees1 closed 2 years ago

Jees1 commented 2 years ago

a

mourner commented 2 years ago

According to the video, you're using Leaflet, not Mapbox GL JS.

Jees1 commented 2 years ago

@mourner The people at Leaflet told me the problem is in Mapbox GL JS.

mourner commented 2 years ago

@Jees1 I'm confused — the video you shared above clearly shows Leaflet, the page you linked doesn't show the map (even after resizing) because of a JS error, but the code uses Maplibre. You would need to set up a clearly reproducible live use case using GL JS for us to be able to diagnose the issue you're describing.

Jees1 commented 2 years ago

I updated it to that one, I will revert the changes for you.

Jees1 commented 2 years ago

@mourner Reverted to GL JS. Check the head of the HTML: link hidden

mourner commented 2 years ago

Looks like you're using mapbox-gl-leaflet plugin — transferred your issue here.

Jees1 commented 2 years ago

The shaking problem was fixed by updating the version. The not showing up part was fixed by removing the map from my page_content div and moved to the body