Guides

Installation

Node.js versions

Compodoc is tested with only LTS versions : v8.11.1, v6.14.1 & v4.9.1

Angular-CLI

Compodoc supports last Angular-CLI version : 6.0.0

Just run Compodoc in a fresh or existing project.

Global installation

Install from npm :

npm install -g @compodoc/compodoc

If you use PowerShell on Windows, add quotes :

npm install -g "@compodoc/compodoc"

Local installation

npm install --save-dev @compodoc/compodoc

Run

Define a script task for it in your package.json :

"scripts": {
  "compodoc": "./node_modules/.bin/compodoc -p src/tsconfig.app.json"
}

and run it like a normal npm script :

npm run compodoc

See usage for more details.

Position of tsconfig file in codebase

Compodoc start at the folder level of the tsconfig file provided with -p option.

Example for an Angular CLI project :

.
├── src
│ ├── app
│ │ ├── app.component.ts
│ │ └── app.module.ts
│ ├── main.ts
│ ├── ...
│ └── tsconfig.app.json
└── tsconfig.json
compodoc -p src/tsconfig.app.json