Google MarkerClusterer: decluster markers below a certain zoom level?

后端 未结 3 665
余生分开走
余生分开走 2020-12-05 23:34

I\'m using Google MarkerClusterer. I\'d like to decluster all the markers whenever the map goes above zoom level 15.

There is a maxZoom setting in the

3条回答
  •  半阙折子戏
    2020-12-06 00:12

     var markerClusterer = new MarkerClusterer(map, myMarkers, {
         maxZoom: 15,
         zoomOnClick: false
       });
    //zoom 0 corresponds to a map of the Earth fully zoomed out, 20 is closeup
    //markerCluster goes away after zoom 
    //turn off zoom on click or spiderfy won't work 
    

提交回复
热议问题