Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Sometimes L.Map.getSize return size with zero #275
I use Leaflet map in modal window on page. Sometimes, on opening this modal window with map - viewport of map appears empty. This behavior can be reproduced when browser window have some special sizes.
I solve this problem by extending check in L.Map.getSize for this._size. When variable this._size set to x:0, y:0 - such problem with viewport appear.
My solution is:
Maybe someone have better solution or code changes must be in other place?