Center map view on current position
All checks were successful
ci/woodpecker/push/build Pipeline was successful

This commit is contained in:
Alessio Davoli 2023-07-18 17:59:12 +02:00
parent e516f9fce5
commit a8264ac7db

View file

@ -58,7 +58,8 @@
minZoom: 12
});
map.setView([latitude, longitude], 13);
var latlng = L.latLng(latitude, longitude);
map.setView(latlng, 13);
map.setMaxBounds(map.getBounds());
leaflet