generated from shuding/nextra-docs-template
-
Notifications
You must be signed in to change notification settings - Fork 6
/
theme.config.tsx
53 lines (51 loc) · 1.33 KB
/
theme.config.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
import React, { PropsWithChildren } from "react";
import Logo from "./components/Logo/logo";
import { useRouter } from "next/router";
import { H1 } from "./components/mdx/H1";
import { DocsThemeConfig } from "nextra-theme-docs";
import { H2 } from "./components/mdx/H2";
const config: DocsThemeConfig = {
logo: <Logo />,
project: {
link: "https://github.com/p2p-org/drpc-nextra",
},
chat: {
link: "https://drpc.org/discord",
},
docsRepositoryBase: "https://github.com/p2p-org/drpc-nextra/blob/main",
head: (
<>
<meta
name="viewport"
content="minimum-scale=1, initial-scale=1, maximum-scale=1, width=device-width"
/>
</>
),
footer: {
component: <></>,
},
components: {
h1: H1,
h2: H2,
},
useNextSeoProps() {
const { asPath } = useRouter();
return {
titleTemplate: "Documentation for dRPC | Docs for dRPC Platform",
description:
"Explore comprehensive documentation for dRPC and streamlining your development process. Discover guides, examples, and tips. 💻📗",
...(asPath === "/" ? { canonical: "https://drpc.org/docs" } : {}),
};
},
sidebar: {
defaultMenuCollapseLevel: 1,
},
nextThemes: {
defaultTheme: "dark",
forcedTheme: "dark",
},
themeSwitch: {
component: () => null,
},
};
export default config;