Open ldrrp opened 8 years ago
My guess is that you have some event handler where every time you zoom/pan, you instantiate a new instance of MarkerClusterer
. So that's why your clusters are so close together - because there are actually two MarkerClusterer
overlays on top of each other.
What you need to do is to:
MarkerClusterer
is instantiated per map, andclearMarkers()
) from the map before redrawing them
Notice i only have 4 markers, and the clusters have two groups of 4. I added a debug console log to count the amount of markers created, at each zoom level only 9 are created in this image total for both zoom levels.