1

Our leaflet web app allows users to switch between tile layers. The tile layers sometimes have different max zoom implemented by the tile provider or local config.

We have another layer with markers, clustered using markerClusterGroup configured to open up the clustering at max zoom AKA spiderfy. The problem is that when the user switches to a tile layer with a smaller max zoom the spiderfy function no longer works.

new L.markerClusterGroup({ spiderfyOnMaxZoom: true }) ...

How can we dynamically tell the markerClusterGroup that max zoom level changed ?

  • Seeing your implementation (code) of marker clustering and layers would greatly help in trying to find solution to your problem. Otherwise it's just guessing. – TomazicM Aug 29 at 19:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.