Fix building static site

This commit is contained in:
Austen Adler 2023-03-24 16:11:06 -04:00
parent 67c5cb977a
commit 8ae3f6543d

View File

@ -2,7 +2,6 @@
import { onMount, onDestroy } from 'svelte';
import { browser } from '$app/environment';
import { createEventDispatcher } from 'svelte';
import * as leafletControlGeocoder from 'leaflet-control-geocoder';
const dispatch = createEventDispatcher();
@ -31,6 +30,7 @@
onMount(async () => {
if (browser) {
const leaflet = await import('leaflet');
const leafletControlGeocoder = await import('leaflet-control-geocoder');
map = leaflet.map(mapElement);
// TODO: Pick a better spot