demo project
This commit is contained in:
11
frontend/src/store.ts
Normal file
11
frontend/src/store.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { writable } from "svelte/store"
|
||||
|
||||
const initLoc = {
|
||||
path: (typeof window !== "undefined" && window.location?.pathname) || "/",
|
||||
search: (typeof window !== "undefined" && window.location?.search) || "",
|
||||
hash: (typeof window !== "undefined" && window.location?.hash) || "",
|
||||
push: false,
|
||||
pop: false,
|
||||
categoryPath: "",
|
||||
}
|
||||
export const location = writable(initLoc)
|
||||
Reference in New Issue
Block a user