forked from CopilotKit/CopilotKit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgen.ts
More file actions
executable file
·24 lines (21 loc) · 717 Bytes
/
Copy pathgen.ts
File metadata and controls
executable file
·24 lines (21 loc) · 717 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import { copyQaSnippetsToMintlify } from "./lib/copy-qa-snippets-to-mintlify";
import { Documentation } from "./lib/doc";
import { getAnnotatedMdxDocs } from "./lib/mdx";
import { copyFileSync } from "fs";
const DOCS_PATH = "../docs";
const CSS_PATH = "packages/react-ui/dist/index.css";
copyQaSnippetsToMintlify();
getAnnotatedMdxDocs(DOCS_PATH)
.then(async (annotations) => {
for (const annotation of annotations) {
const doc = new Documentation(annotation);
await doc.generate();
}
})
.then(async () => {
// copy over the style.css file
copyFileSync(CSS_PATH, "../docs/_snippets/style.css");
})
.catch((error) => {
console.error("Error generating docs:", error);
});