wm-fontis-tibi-2023/frontend/src/App.svelte

23 lines
495 B
Svelte
Raw Normal View History

2023-07-13 13:12:19 +02:00
<script lang="ts">
2023-07-13 15:20:36 +02:00
import { location } from "./store"
2023-07-13 13:12:19 +02:00
export let url = ""
if (url) {
// ssr
let l = url.split("?")
$location = {
path: l[0],
search: l.length > 1 ? l[1] : "",
hash: "",
categoryPath: l[0].replace(/\/[^_\/]+_[^\/]+$/, ""),
push: false,
pop: false,
}
}
if (typeof window !== "undefined") console.log("App initialized")
</script>
<h1>Hello World</h1>