Skip to content

Commit 74bff3e

Browse files
committed
chore: add typedoc
1 parent 8c8ac17 commit 74bff3e

File tree

3 files changed

+150
-0
lines changed

3 files changed

+150
-0
lines changed

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@
6464
"types": "dist/index.d.ts",
6565
"scripts": {
6666
"build": "unbuild && pnpx tsx ./scripts/deno.ts",
67+
"build:docs": "typedoc --excludeInternal",
6768
"changelog": "gh-changelogen --repo=intlify/utils",
6869
"dev:eslint": "pnpx @eslint/config-inspector --config eslint.config.ts",
6970
"fix": "pnpm run --color \"/^fix:/\"",
@@ -128,6 +129,8 @@
128129
"supertest": "^6.3.3",
129130
"typescript": "^5.9.3",
130131
"typescript-eslint": "^8.46.3",
132+
"typedoc": "^0.28.14",
133+
"typedoc-plugin-markdown": "^4.9.0",
131134
"unbuild": "^3.6.1",
132135
"vitest": "catalog:vitest",
133136
"vitest-environment-miniflare": "^2.14.1"

pnpm-lock.yaml

Lines changed: 119 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

typedoc.config.mjs

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
// @ts-check
2+
3+
export default {
4+
/**
5+
* typedoc options
6+
* ref: https://typedoc.org/documents/Options.html
7+
*/
8+
entryPoints: ['./src/index.ts'],
9+
out: 'docs',
10+
plugin: ['typedoc-plugin-markdown'],
11+
readme: 'none',
12+
groupOrder: ['Variables', 'Functions', 'Class'],
13+
/**
14+
* typedoc-plugin-markdown options
15+
* ref: https://typedoc-plugin-markdown.org/docs/options
16+
*/
17+
entryFileName: 'index',
18+
hidePageTitle: false,
19+
useCodeBlocks: true,
20+
disableSources: true,
21+
indexFormat: 'table',
22+
parametersFormat: 'table',
23+
interfacePropertiesFormat: 'table',
24+
classPropertiesFormat: 'table',
25+
propertyMembersFormat: 'table',
26+
typeAliasPropertiesFormat: 'table',
27+
enumMembersFormat: 'table'
28+
}

0 commit comments

Comments
 (0)