mirror of
https://github.com/hanzo-docs/docs.git
synced 2026-10-27 09:19:53 +00:00
23 lines
469 B
TypeScript
23 lines
469 B
TypeScript
import { register } from 'fumadocs-mdx/node';
|
|
import { postInstall } from 'fumadocs-mdx/vite';
|
|
import { writeFile } from 'node:fs/promises';
|
|
|
|
register();
|
|
|
|
await postInstall({
|
|
index: {
|
|
target: 'default',
|
|
},
|
|
});
|
|
|
|
export interface Info {
|
|
prerender: string[];
|
|
}
|
|
|
|
const { source } = await import('../app/lib/source.ts');
|
|
const info: Info = {
|
|
prerender: source.getPages().map((page) => page.url),
|
|
};
|
|
|
|
await writeFile('.react-router/_info', JSON.stringify(info));
|