TypeDoc
Documentation generator for TypeScript projects.
Installation
TypeDoc runs on Node.js and is available as an NPM package. You can install TypeDoc in your project's directory as usual:$ npm install typedoc --save-dev
Like the TypeScript compiler, TypeDoc comes with a binary that can be called from anywhere if you install TypeDoc as a global module. The name of the executable is `
typedoc
`.$ npm install typedoc --global
$ typedoc
Usage
Shell
TypeDoc accepts most of the command line arguments that the TypeScript compiler accepts. One major difference is the fact that one may pass an entire directory instead of individual files to the documentation generator. So in order to create a documentation for an entire project you simply type:$ typedoc --out path/to/documentation/ path/to/typescript/project/
Important note
Starting with version 0.2, TypeDoc no longer can predict whether files should be treated as modules or whether the project should be compiled into one big namespace. You must specify themode
argument
in order to change the behaviour of TypeDoc.Arguments
--out <path/to/documentation/>
--mode <file|modules>
--options
--json <path/to/output.json>
--ignoreCompilerErrors
Source file handling
--exclude <pattern>
--includeDeclarations
--externalPattern <pattern>
--excludeExternals
--excludePrivate
TypeScript compiler
--module <commonjs, amd, system or umd>
--target <ES3, ES5, or ES6>
Theming
--theme <default|minimal|path/to/theme>
--name <Documentation title>
--readme <path/to/readme|none>
none
to disable the index page
and start the documentation on the globals page.--plugin
--hideGenerator
--gaID
--gaSite <site>
auto
--entryPoint <fully.qualified.name>
--gitRevision <revision|branch>
Content
--includes <path/to/includes>
include:FILENAME
in comments to include documents from this location.--media <path/to/media>
media://FILENAME
in comments.Miscellaneous
--version
--help
Webpack
There is a plugin available to run TypeDoc with Webpack created by Microsoft. You can find it on NPM:https://www.npmjs.com/package/typedoc-webpack-plugin
Gulp
There is a plugin available to run TypeDoc with Gulp created by Rogier Schouten. You can find it on NPM:https://www.npmjs.org/package/gulp-typedoc/
Grunt
There is a plugin available to run TypeDoc with Grunt created by Bart van der Schoor. You can find it on NPM:https://www.npmjs.org/package/grunt-typedoc
Plugins
- External Module Name - Set the name of TypeDoc external modules
- Sourcefile URL - Set custom source file URL links
- Internal/External Module - Explicitly mark modules as
@internal
or@external
- Single Line Tags - Process certain
@tags
as single lines
Advanced guides and docs
Visit our homepage for advanced guides and an extensive API documentation:http://typedoc.org
Contributing
This project is maintained by a community of developers. Contributions are welcome and appreciated. You can find TypeDoc on GitHub; feel free to start an issue or create a pull requests:https://github.com/TypeStrong/typedoc
License
Copyright (c) 2015 Sebastian Lenz.Copyright (c) 2016-2017 TypeDoc Contributors.
Licensed under the Apache License 2.0.