forked from nixcn/nixcn-cms
feat(client): setup tanstack router
Signed-off-by: Noa Virellia <noa@requiem.garden>
This commit is contained in:
17
client/src/routes/__root.tsx
Normal file
17
client/src/routes/__root.tsx
Normal file
@@ -0,0 +1,17 @@
|
||||
import { createRootRoute, Outlet } from '@tanstack/react-router';
|
||||
import { TanStackRouterDevtools } from '@tanstack/react-router-devtools';
|
||||
import { ThemeProvider } from '@/components/theme-provider';
|
||||
import '@/index.css';
|
||||
|
||||
function RootLayout() {
|
||||
return (
|
||||
<>
|
||||
<ThemeProvider defaultTheme="dark" storageKey="vite-ui-theme">
|
||||
<Outlet />
|
||||
</ThemeProvider>
|
||||
<TanStackRouterDevtools />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
export const Route = createRootRoute({ component: RootLayout });
|
||||
Reference in New Issue
Block a user