I’m able to get the location from the browser using:
<script>
function setMapPosition(position) {
const pos = {
lat: position.coords.latitude,
lng: position.coords.longitude,
};
console.log(pos);
}
navigator.geolocation.getCurrentPosition(setMapPosition);
</script>
And from this method, I want to call the method from Google Map objectsetCenter(pos)
documented here Géolocalisation : affichage de l'emplacement d'un utilisateur ou d'un appareil sur une carte | API Maps JavaScript | Google for Developers
But how I can get the instance of my map defined in a Softr block?
Thank you