API Doc generator rewritten from YUIDoc. We use this tool to self-document firedoc itself at:
$ npm install -g firedoc
Usage: firedoc [options] [command]Commands:build [path] build document from the directoryinstall [path] install theme or pluginpreview [path] build and preview the document from directoryhelp [cmd] display help for [cmd]Options:-h, --help output usage information-V, --version output the version number
$ firedoc build <path> --lang <lang>
Or using a shortcut command:
$ firedoc <path> --lang <lang>
The following is the helper of
Usage: firedoc-build [options]Options:-h, --help output usage information-l --lint lint the parser--parse-only only parse-H --http build doc for web-M --markdown generate markdown docs-T --theme <dir> specify theme directory-D --dest <dir> the destination folder to build-L --lang <language> the i18n language-S --source whether or not output source files and show the link in 'Defined in' section.-v --verbose print all verbose information
--lang option is required for multi-language description. Currently firedoc supports
zh language option. Adding those option will generate docs for that specific language.
-M is optional flag, which lets you get the markdown-based documentation to
directly host at Github or Bitbucket. Firedoc's github
hosted documentation is generated by itself.
For sites that requires a base url (such as
http://mysite.com/docs), specify a
baseurl property in your
If you want to preview your api docs with local html files, add a
to your config file.
By default the firedoc provides the following 3 themes:
firedoc build <path> --theme [path/to/your/theme]
$ firedoc install notab$ firedoc install firedoc-theme-notab$ firedoc install https://github.com/fireball-x/firedoc-theme-notab
The above command will install the theme firedoc-theme-notab into installed firedoc directory in your machine. Then you would be able to use the theme just like this:
$ firedoc build <path> --theme notab
However if the remote url has a same basename with what you have installed in your machine, then you can specify a different name to install it:
$ firedoc install <url> --name different-theme-name
If you are wanting to write a new theme and need some details, you could go to: themes README.
Note: please make sure you have the installed following dependencies before using theme functionality:
To run test
$ npm test
Please see the CONTRIBUTING.md.
This software is free to use under the Yahoo Inc. BSD license. See the LICENSE file for license text and copyright information.