docs: guide setup (#10862)

This commit is contained in:
Noel
2025-04-28 02:23:27 +02:00
committed by GitHub
parent 291012c18a
commit 2184085fda
58 changed files with 4996 additions and 3361 deletions

View File

@@ -0,0 +1,24 @@
import { rehypeCodeDefaultOptions } from 'fumadocs-core/mdx-plugins';
import { defineConfig, defineDocs } from 'fumadocs-mdx/config';
import { transformerTwoslash } from 'fumadocs-twoslash';
import { createFileSystemTypesCache } from 'fumadocs-twoslash/cache-fs';
export const docs = defineDocs({
dir: 'content/docs',
});
transformerTwoslash({
typesCache: createFileSystemTypesCache(),
});
export default defineConfig({
mdxOptions: {
rehypeCodeOptions: {
themes: {
light: 'github-light',
dark: 'github-dark',
},
transformers: [...(rehypeCodeDefaultOptions.transformers ?? []), transformerTwoslash()],
},
},
});