Skip to content

Commit 678b39e

Browse files
authored
update docs (#12)
1 parent a333c03 commit 678b39e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+26
-2268
lines changed

.github/workflows/deploy.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
run: |
2222
cd docs
2323
npm install
24+
npm run docs:api
2425
npm run docs:build
2526
- uses: actions/configure-pages@v3
2627
- uses: actions/upload-pages-artifact@v2

docs/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
cache
2+
api

docs/.vitepress/config.ts

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { defineConfig } from "vitepress";
1+
import { defineConfig, DefaultTheme } from "vitepress";
22
import md from "./md";
33
import escapeCode from "./escape-code";
44
import imgit from "imgit/vite";
@@ -71,11 +71,16 @@ export default defineConfig({
7171
]
7272
}
7373
],
74-
"/api/": [{
75-
text: "Reference",
76-
items: (await import("./../api/typedoc-sidebar.json")).default
77-
}]
74+
"/api/": await getApiSidebar()
7875
}
7976
},
8077
sitemap: { hostname: "https://imgit.dev" }
8178
});
79+
80+
async function getApiSidebar(): Promise<DefaultTheme.SidebarItem[]> {
81+
const items = (await import("./../api/typedoc-sidebar.json")).default;
82+
const server = items.find(i => i.text === "server");
83+
const client = items.find(i => i.text === "client");
84+
const other = items.filter(i => i !== server && i !== client);
85+
return [{ text: "Reference", items: [server, client, ...other] }];
86+
}

docs/api/index.md

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

docs/api/plugin/astro/functions/default.md

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

docs/api/plugin/astro/index.md

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

docs/api/plugin/astro/type-aliases/AstroInjector.md

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

docs/api/plugin/astro/type-aliases/AstroIntegration.md

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

docs/api/plugin/svg/functions/default.md

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

docs/api/plugin/svg/index.md

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

0 commit comments

Comments
 (0)