fixes trail flashing on home nav

This commit is contained in:
Christian Beutel
2024-12-01 22:00:53 +01:00
parent 1ad7fb3820
commit b1d163a0a4
3 changed files with 15 additions and 8 deletions

View File

@@ -1,8 +1,11 @@
import type { Trail } from "$lib/models/trail";
import { categories_index } from "$lib/stores/category_store";
import { trails_index } from "$lib/stores/trail_store";
import type { ServerLoad } from "@sveltejs/kit";
export const load: ServerLoad = async ({ params, locals, fetch }) => {
await trails_index(20, true, fetch)
const trails: Trail[] = await trails_index(20, true, false, fetch)
await categories_index(fetch)
return {trails}
};