Generate Markdown documentation

npm install doccy
10 downloads in the last week
20 downloads in the last month


Build Status

$ npm install -g doccy

Automatic generation of documentation READMEs.

(Still very much under development).


You can see a full example of generated documentation in the docs folder.

Given a test file:

 * @object thing
 * @description a module of things
var thing = {
     * @name foo
     * @description a cool function
     * @param x does something
     * @returns a number
    foo: function(x) {
        return 42;


$ doccy test.js -o docs

Will create docs/ that looks like so:

## `thing`

_a module of things_

### `foo`

_a cool function_


- `x`: does something

**Returns:** a number

If you'd like a full example, the Doccy documentation is generated from Doccy itself.

CLI Globbing

Rather than specify each file individually, the more common use of Doccy's small CLI tool is to pass in a glob:

$ doccy "src/*.js"

Will create a Markdown documentation file for each JS file within the src directory. By default doccy will put these into a docs folder, that it will create if needed, but you can specify the output directory with the -o flag:

$ doccy "src/*.js" -o documentation

Supported Keys

Order is not important, and things within [] are optional.

  • @name function_name
  • @description function_description
  • @param name [{Type}] description
  • @returns description
  • @object name - denotes a "containing" object (see above example, which is much clearer)


  • allow options for changing Markdown formatting
  • add more keys
  • make a Grunt plugin
  • document programmatical usage


Thanks to the following people for their help :)


Please follow the existing style of code - recommend using EditorConfig to help you out with this.

To generate documentation, run npm run doccy.



  • added type support to @param


  • added CLI tool for globbing support


  • added object key for denoting a "containing" object


  • added description key


  • initial release
npm loves you