Skip to content

Commit ff4faaa

Browse files
committed
docs: move to SolidBase
1 parent e95a81e commit ff4faaa

31 files changed

Lines changed: 3416 additions & 3053 deletions

docs/README.md

Lines changed: 0 additions & 29 deletions
This file was deleted.

docs/app.config.ts

Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
import * as fs from "node:fs";
2+
import * as path from "node:path";
3+
import { createWithSolidBase } from "@kobalte/solidbase/config";
4+
import defaultTheme, {
5+
type SidebarItem,
6+
} from "@kobalte/solidbase/default-theme";
7+
import { defineConfig } from "@solidjs/start/config";
8+
9+
export default defineConfig(
10+
createWithSolidBase(defaultTheme)(
11+
{
12+
ssr: true,
13+
server: {
14+
preset: "cloudflare-pages",
15+
},
16+
},
17+
{
18+
title: "Solid Relay",
19+
description: "SolidJS Bindings for Relay",
20+
lang: "en",
21+
issueAutolink: "https://github.com/XiNiHa/solid-relay/issues/:issue",
22+
editPath: "https://github.com/XiNiHa/solid-relay/edit/main/docs/:path",
23+
themeConfig: {
24+
socialLinks: {
25+
// @ts-ignore
26+
github: "https://github.com/XiNiHa/solid-relay",
27+
},
28+
nav: [
29+
{
30+
text: "Guide",
31+
link: "/guide",
32+
},
33+
{
34+
text: "API",
35+
link: "/api",
36+
},
37+
],
38+
sidebar: {
39+
"/guide": {
40+
items: [
41+
{
42+
title: "Overview",
43+
collapsed: false,
44+
items: [
45+
{
46+
title: "Getting Started",
47+
link: "/",
48+
},
49+
],
50+
},
51+
],
52+
},
53+
"/api": {
54+
items: [
55+
{
56+
title: "API Reference",
57+
collapsed: false,
58+
items: [
59+
{
60+
title: "Index",
61+
link: "/",
62+
},
63+
],
64+
},
65+
...(await Promise.all(
66+
["Functions", "Interfaces"].map(
67+
async (section): Promise<SidebarItem> => {
68+
const dir = section.toLowerCase();
69+
const items = await fs.promises.readdir(
70+
path.join(import.meta.dirname, "src/routes/api", dir),
71+
);
72+
73+
return {
74+
title: section,
75+
collapsed: false,
76+
items: items.map((item) => {
77+
const name = path
78+
.basename(item)
79+
.replace(path.extname(item), "");
80+
return {
81+
title: name,
82+
link: `/${dir}/${name}`,
83+
};
84+
}),
85+
};
86+
},
87+
),
88+
)),
89+
],
90+
},
91+
},
92+
},
93+
},
94+
),
95+
);

docs/docs/_meta.json

Lines changed: 0 additions & 12 deletions
This file was deleted.

docs/docs/guide/_meta.json

Lines changed: 0 additions & 1 deletion
This file was deleted.

docs/docs/public/favicon.png

-319 Bytes
Binary file not shown.

docs/package.json

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,30 @@
11
{
22
"name": "solid-relay-docs",
3+
"type": "module",
34
"private": true,
45
"scripts": {
5-
"dev": "rspress dev",
6-
"build": "rspress build",
7-
"preview": "rspress preview"
6+
"dev": "vinxi dev",
7+
"build": "typedoc && vinxi build",
8+
"preview": "vinxi preview"
89
},
910
"dependencies": {
10-
"rspress": "^1.43.10"
11+
"@fontsource-variable/inter": "^5.2.5",
12+
"@fontsource-variable/jetbrains-mono": "^5.2.5",
13+
"@fontsource-variable/lexend": "^5.2.6",
14+
"@kobalte/solidbase": "^0.2.0",
15+
"@solidjs/meta": "^0.29.4",
16+
"@solidjs/router": "^0.15.3",
17+
"@solidjs/start": "^1.1.3",
18+
"@vinxi/plugin-mdx": "^3.7.2",
19+
"solid-js": "^1.9.5",
20+
"solid-mdx": "^0.0.7",
21+
"vinxi": "^0.5.3"
1122
},
1223
"devDependencies": {
13-
"@rspress/plugin-typedoc": "^1.43.10",
24+
"@iconify-json/ri": "^1.2.5",
1425
"@types/node": "^22.14.0",
15-
"solid-relay": "workspace:^"
26+
"solid-relay": "workspace:^",
27+
"typedoc": "^0.28.1",
28+
"typedoc-plugin-markdown": "^4.6.1"
1629
}
1730
}

docs/public/favicon.ico

Whitespace-only changes.

docs/rspress.config.ts

Lines changed: 0 additions & 31 deletions
This file was deleted.

docs/src/app.tsx

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { SolidBaseRoot } from "@kobalte/solidbase/client";
2+
import { Router } from "@solidjs/router";
3+
import { FileRoutes } from "@solidjs/start/router";
4+
5+
export default function App() {
6+
return (
7+
<Router root={SolidBaseRoot}>
8+
<FileRoutes />
9+
</Router>
10+
);
11+
}

docs/src/entry-client.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// @refresh reload
2+
import { StartClient, mount } from "@solidjs/start/client";
3+
4+
// biome-ignore lint/style/noNonNullAssertion: always exists
5+
mount(() => <StartClient />, document.getElementById("app")!);

0 commit comments

Comments
 (0)