我想知道是否有办法从package.json
生成节点模块的文档(HTML,txt等)。
我们假设这是我的package.json
{
"name": "ov-aib-phone",
"version": "1.0.0",
"description": "Utility for handling phone numbers stored in CIF database",
"main": "index.js",
"repository": {
"type": "git",
"url": "https://gitstash.aib.pri/scm/ovc/ov-aib-phone.git"
},
"author": "OneView Team",
"license": "ISC",
"devDependencies": {
"aib-build-utils": "1.0.1",
"gulp": "3.9.1",
"gulp-clean": "0.3.2",
"gulp-concat": "2.6.0",
"gulp-minify-html": "1.0.5",
"gulp-ng-annotate": "2.0.0",
"gulp-ng-html2js": "0.2.2",
"gulp-rename": "1.2.2",
"gulp-sourcemaps": "1.6.0",
"gulp-uglify": "2.0.0",
"run-sequence": "1.2.1"
},
"dependencies": {
"angular": "1.5.9",
"angular-messages": "1.5.9"
},
"files": [
"dist/"
]
}
我想只是一个插件,它生成一个与模块相关的文档(不是其中的代码!),而只是名称,repo URL和依赖项。
我知道我可以写它,因为我只需要解析JSON并生成一个文件(HTML会好得多),但我想知道轮子是否已经为它发明了。
非常感谢