安装typedoc:
npm install typedoc --save-dev
然后在tsconfig.json中添加typedocOptions:
{
"compileOnSave": false,
"compilerOptions": {
"baseUrl": "./",
// ...some lines there
"typeRoots": [
"node_modules/@types"
],
"lib": [
"es2018",
"dom"
],
"emitDecoratorMetadata": true
},
"angularCompilerOptions": {
"fullTemplateTypeCheck": true,
"strictInjectionParameters": true
},
"typedocOptions": {
"mode": "modules",
"out": "docs"
}
}
那我就做了
npx typedoc --out docs src/index.ts
并得到错误:
Error: Tried to set an option (mode) that was not declared.
我该怎么解决?
1条答案
按热度按时间ny6fqffe1#
从v0.20.0起,
mode
选项已被删除,如release notes中所述。完整的选项列表可以在documentation中看到。相关文章here