leaflet-extras / leaflet-providers

An extension to Leaflet that contains configurations for various free tile providers.
https://leaflet-extras.github.io/leaflet-providers/preview/
BSD 2-Clause "Simplified" License
2.15k stars 668 forks source link

Too slow at the first load #308

Closed Kianoosh76 closed 5 years ago

Kianoosh76 commented 5 years ago

Hi! Thanks for your wonderful map, the only problem there is that in the very first load, it takes too much time to load the map and since it's an inline js, nothing is shown on the web page while loading the map! This may affect the users' experience!

jieter commented 5 years ago

How would you propose to fix this? I think the target use of this line is not really in simple map views in news articles, but rather data exploration platforms.

Kianoosh76 commented 5 years ago

So at least it might be better to release a lighter version (if possible) for ordinary usage, cause since Google Maps is no longer free, every developer needs an alternative one badly!

jieter commented 5 years ago

The source file is 22k, 16k minified. If you are concerned about the size I suggest selecting a couple of layers and add them to your map without including leaflet-providers.