Markdox is a documentation generator based on Dox and Markdown with support for JavaScript, CoffeeScript and IcedCoffeeScript.
This plugin is a gulp
wrapper for it.
First, install gulp-markdox
as a development dependency:
npm install --save-dev gulp-markdox
Then, add it to your gulpfile.js
:
var markdox = require("gulp-markdox");
gulp.task("doc", function(){
gulp.src("./src/*.js")
.pipe(markdox())
.pipe(gulp.dest("./doc"));
});
It can take on .coffee
and .iced
files, too.
If you want to concatenate all your generated documentation files, use gulp-concat:
var markdox = require("gulp-markdox");
var concat = require("gulp-concat");
gulp.task("doc", function(){
gulp.src("./src/*.js")
.pipe(markdox())
.pipe(concat("doc.md"))
.pipe(gulp.dest("./doc"));
});
Please refer to markdox's documentation for further documentation of these options.x'
Type: String
Path or the custom template
Type: String
Default: utf-8
Encoding of templates and files to parse
Type: Function
Custom formatter
Type: Function
Custom compiler