cof

coffdoc

CoffeeScript Document Generator

Showing:

Popularity

Downloads/wk

3

GitHub Stars

5

Maintenance

Last Commit

6yrs ago

Contributors

0

Package

Dependencies

5

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

coffdoc

Rapid generation of CoffeeScript documents.

Demo image demo

How to use it?

Command line

Install

# bash
npm install -g coffdoc

Quickly Use

Through all coffee files in the current directory and save the generated documentation to ./doc

# bash

coffdoc

Switch

  • -p or --projectPath, default: ./

    if there is only one parameter then you can ignore -p flag and direct input coffdoc folderName

  • -n or --projectName, default: The current directory name

  • -d or --docPath, default: ./doc

# bash
coffdoc -p testhello -n "project Hello" -d ./documentation

gulp

Install

# bash
npm install coffdoc --save-dev

Use

# gulpfile.coffee
coffdoc = require 'coffdoc'

gulp.task 'doc', ->

    coffdoc
        projectPath: './src'
        projectName: 'cofdoc'
        docPath: './documentation'

About comment

You can use the docblockr plugin to generate a comment block quickly.

Use the internal functions comment

say = (str) ->
    ###*
     * Output some text.
     * @param  {String}  str The string to be displayed
     * @return {Boolean}     Some boolean value
    ###

    console.log str
    return true

say 'hello'

You can also use the function outside comments (low priority)

###*
 * Output some text.
 * @param  {String}  str The string to be displayed
 * @return {Boolean}     Some boolean value
###
say = (str) ->
    console.log str
    return true

say 'hello'

Mulitipe tag

say = (str1, str2) ->
    ###*
     * Output some text.
     * @param  {String}  str1 The string to be displayed
     * @param  {Number}  str2 The number to be displayed, if you wanna Wrap,
     *                        then you need maintaining consistent indentation.
     * @return {Boolean}      Some boolean value
    ###

    console.log str1, str2
    return true

say 'hello'

Use markdown in description

say = (str) ->
    ###*
     * Output some `String`, maybe some `Number`,
     * Some **else** text.
     * @param  {String}  str The string to be displayed
     * @return {Boolean}     Some boolean value
    ###

    console.log str
    return true

say 'hello'

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Alternatives

No alternatives found

Tutorials

No tutorials found
Add a tutorial