Skip to main content
Tweeted twitter.com/StackGIS/status/889706321330745344
Source Link

How to add 'top' and 'bottom' directions with leaflet marker label

I need to add a label to marker from bottom. But there are no any value to add for direction option in bindLabel method.

 var marker = L.marker([ latitude, longitude ], {
         icon : iconInfo,
         iconAnchor: [10, 10],
         labelAnchor: [6, 0]
     }).bindLabel(displayingText, {
         direction: 'right',
         noHide : true
     }).addTo(leaf_map);

It only have right|left|auto options only. How can I achieve this with leaflet marker ?