only load on click

This commit is contained in:
Zsolt Ero
2024-03-25 01:00:54 +01:00
parent 442fb383d4
commit c5c555f662

View File

@@ -34,13 +34,14 @@ function initMap() {
}
const mapDiv = document.getElementById('map-container')
// mapDiv.onclick = function () {
// initMap()
// }
mapDiv.onclick = function () {
initMap()
}
initMap()
// initMap()
function selectStyle(event, style) {
initMap()
toggleButtonSelection(event.target)
const styleUrl = 'https://tiles.openfreemap.org/styles/' + style