We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 405d901 commit 49796d0Copy full SHA for 49796d0
src/app/docs/layout.tsx
@@ -1,12 +1,16 @@
1
-import { DocsLayout } from "fumadocs-ui/layouts/docs";
+import { DocsLayout, DocsLayoutProps } from "fumadocs-ui/layouts/notebook";
2
import type { ReactNode } from "react";
3
import { baseOptions } from "@/app/layout.config";
4
import { source } from "@/lib/source";
5
6
+const docsLayoutOptions: DocsLayoutProps = {
7
+ tree: source.pageTree,
8
+ ...baseOptions,
9
+ themeSwitch: {
10
+ mode: "light-dark",
11
+ },
12
+};
13
+
14
export default function Layout({ children }: { children: ReactNode }) {
- return (
- <DocsLayout tree={source.pageTree} {...baseOptions}>
- {children}
- </DocsLayout>
- );
15
+ return <DocsLayout {...docsLayoutOptions}>{children}</DocsLayout>;
16
}
0 commit comments