Add typedef
All checks were successful
ci/woodpecker/push/build Pipeline was successful

This commit is contained in:
Alessio Davoli 2023-12-18 15:56:52 +01:00
parent bd12df0b8a
commit 094dd5b070

View file

@ -31,7 +31,7 @@
maximumAge: 0, maximumAge: 0,
}; };
function success(pos) { function success(pos: GeolocationPosition) {
const crd = pos.coords; const crd = pos.coords;
let string = ""; let string = "";
@ -82,11 +82,11 @@
await watchPosition(); await watchPosition();
leaflet = await import('leaflet'); leaflet = await import('leaflet');
renderMap() renderMap();
}); });
onDestroy(async () => { onDestroy(async () => {
if(watchPositionId) { if (watchPositionId) {
navigator.geolocation.clearWatch(watchPositionId); navigator.geolocation.clearWatch(watchPositionId);
} }
if (map) { if (map) {