Closed littlebeeper closed 9 years ago
Below is the usage example from leaflet documentation.
// create a red polyline from an arrays of LatLng points var polyline = L.polyline(latlngs, {color: 'red'}).addTo(map);
// zoom the map to the polyline map.fitBounds(polyline.getBounds());
There is no way for creating bounds from given Latlngs or from a path array
Did you ever figure this out?
I'm going to close this as old issue, there are some examples of how to use the bounds facilities here:
http://tombatossals.github.io/angular-leaflet-directive/examples/0000-viewer.html#/basic/bounds-example
Below is the usage example from leaflet documentation.
// create a red polyline from an arrays of LatLng points var polyline = L.polyline(latlngs, {color: 'red'}).addTo(map);
// zoom the map to the polyline map.fitBounds(polyline.getBounds());
There is no way for creating bounds from given Latlngs or from a path array