How to locate leaflet zoom control in a desired position

前端 未结 6 946
鱼传尺愫
鱼传尺愫 2020-12-08 19:11

I want to place the zoom control in middle right of the the map i.e. in the middle of the right most side of the map. I have found solution to put the zoom control in differ

6条回答
  •  不知归路
    2020-12-08 19:33

    this worked for me

    var map = new L.map("map-container",{ zoomControl: false });
    
    L.control.zoom({ position: 'topright' }).addTo(map);
    

提交回复
热议问题