| 1 | import { lazy } from "solid-js"; |
| 2 | import type { RouteDefinition } from "@solidjs/router"; |
| 3 | |
| 4 | import Home from "./pages/home"; |
| 5 | import AboutData from "./pages/about.data"; |
| 6 | |
| 7 | export const routes: RouteDefinition[] = [ |
| 8 | { |
| 9 | path: "/", |
| 10 | component: Home, |
| 11 | }, |
| 12 | { |
| 13 | path: "/about", |
| 14 | component: lazy(() => import("./pages/about")), |
| 15 | data: AboutData, |
| 16 | }, |
| 17 | { |
| 18 | path: "**", |
| 19 | component: lazy(() => import("./errors/404")), |
| 20 | }, |
| 21 | ]; |