Skeleton: Delegate data fetching to specific routes and only load what's needed
This commit is contained in:
8
src/routes/data/season/races/+page.ts
Normal file
8
src/routes/data/season/races/+page.ts
Normal file
@ -0,0 +1,8 @@
|
||||
import { fetch_races } from "$lib/fetch";
|
||||
import type { PageLoad } from "../../../$types";
|
||||
|
||||
export const load: PageLoad = async ({ fetch }) => {
|
||||
return {
|
||||
races: fetch_races(fetch),
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user