20 lines
407 B
TypeScript
20 lines
407 B
TypeScript
import "./style.css";
|
|
import { initMap } from "./map.ts";
|
|
import { checkAuth, renderAuthBar, setOnAuthChange } from "./auth.ts";
|
|
import { loadPins, setupMapClick } from "./pins.ts";
|
|
|
|
async function main(): Promise<void> {
|
|
initMap();
|
|
await checkAuth();
|
|
renderAuthBar();
|
|
await loadPins();
|
|
setupMapClick();
|
|
|
|
setOnAuthChange(async () => {
|
|
renderAuthBar();
|
|
await loadPins();
|
|
});
|
|
}
|
|
|
|
main();
|