Open History to see the last commit
1import {
2 HeadContent,
3 Outlet,
4 Scripts,
5 createRootRouteWithContext,
6} from '@tanstack/solid-router'
7import { TanStackRouterDevtools } from '@tanstack/solid-router-devtools'
8
9import { HydrationScript } from 'solid-js/web'
10import { Suspense } from 'solid-js'
11
12import Header from '../components/Header'
13
14import styleCss from '../styles.css?url'
15
16export const Route = createRootRouteWithContext()({
17 head: () => ({
18 links: [{ rel: 'stylesheet', href: styleCss }],
19 }),
20 shellComponent: RootComponent,
21})
22
23function RootComponent() {
24 return (
25 <html>
26 <head>
27 <HydrationScript />
28 </head>
29 <body>
30 <HeadContent />
31 <Suspense>
32 <Header />
33 <Outlet />
34 <TanStackRouterDevtools />
35 </Suspense>
36 <Scripts />
37 </body>
38 </html>
39 )
40}