The .doclets.yml configuration file

CI with Tags and Branches

Documentation will be generated for all tags and selected branches (defaults are 'master' and 'add-to-doclets'). To add branches to Doclets.io use the branches entry.

Doclets.io requires a small configuration file to create your repository's API-Doc. This file must be placed in the root directory of you repository similar to the popular .travis.yml for Travis-CI.

Example 1

This example tells Doclets.io to parse the file index.js for JSDoc comments.

files:

  - index.js

Example 2

This example tells Doclets.io to parse all files within the lib for JSDoc comments. It also defines the packageJson to be considered for additional information about the project and includes two markdown articles to be named "Overview" and "Todo App" respectively.

dir: lib

packageJson: package.json

articles:

  - Overview: README.md

  - Todo App: examples/todo/README.md

Example 3

This example tells Doclets.io to parse all files within the lib for JSDoc comments. It also adds the 'next' branch for automatic doc generation.

dir: lib

branches:

  - master

  - next

Explained

NameDescription
dirSpecifies a directory to parse for JSDoc comments. Usually this is "src" or "lib".
filesSpecifies an array of files to parse for JSDoc comments. If your code is in a single file e.g. "index.js" this is also your choice.
branchesSpecifies an array of branch names for which doc generation will be enabled. Defaults to ['master', 'add-to-doclets']
packageJsonSpecifies a package.json file path. Adds additional info to the repository.
articlesA key/value array which allows to include Markdown files into the generated doclet. The key is the article name as listed in the API-Doc and the value id the path to the Markdown file to include with your repo.
Either dir or files must be defined! Other fields are optional.