React-mapbox-gl: Issues with resizing (potentially due to flexbox container)

Created on 14 Nov 2017  路  2Comments  路  Source: alex3165/react-mapbox-gl

Echoing #395, there seems to be issues when the container resizes due to new elements / the window itself resizing. Not sure if this webpackbin is 100% replicating what I'm seeing on my end, but it does show how the map can fail to resize (both with and without a manual call to the mapbox .resize() function (try commenting out line 37).

I've also tried to not use flexbox (and instead have the container use inline-block) but the issue still arises.

https://www.webpackbin.com/bins/-KyrdSeFI0dpMmkHEuCx

Happy to add more details if necessary! Attached also is a screenshot of the issue on my current build; it arises when you toggle the tabs on the top left to hide/show the map view. If you drag to resize the window it corrects.

image

Most helpful comment

^that wasn't much help as the link is broken.

All 2 comments

@romeboards Sorry for the late reply, you need to resize after you actually update the style of the container, see: https://www.webpackbin.com/bins/-KzVbA5I7NKGyiSNEVhL

^that wasn't much help as the link is broken.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jesster2k10 picture jesster2k10  路  3Comments

loverdeveloper picture loverdeveloper  路  3Comments

rofrol picture rofrol  路  4Comments

stereobooster picture stereobooster  路  4Comments

spybaby1 picture spybaby1  路  4Comments