forked from webpack/webpack-doc-kit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgenerate-md.mjs
More file actions
33 lines (27 loc) · 746 Bytes
/
generate-md.mjs
File metadata and controls
33 lines (27 loc) · 746 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
25
26
27
28
29
30
31
32
33
import { Application } from 'typedoc';
import webpack from './webpack/package.json' with { type: 'json' };
import { major } from 'semver';
const app = await Application.bootstrapWithPlugins({
entryPoints: ['./webpack/types.d.ts'],
out: `pages/v${major(webpack.version)}.x`,
// Plugins
plugin: [
'typedoc-plugin-markdown',
'./plugins/processor.mjs',
'./plugins/theme/index.mjs',
],
theme: 'doc-kit',
router: 'doc-kit',
// Formatting
hideGroupHeadings: true,
hideBreadcrumbs: true,
hidePageHeader: true,
disableSources: true,
propertiesFormat: 'table',
entryFileName: 'index',
tsconfig: 'tsconfig.json',
});
const project = await app.convert();
if (project) {
await app.generateOutputs(project);
}