Markdown
This plugin requires Grunt ~0.4.1
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-sundown --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt.loadNpmTasks('grunt-sundown');
You can find the project on Github.
In your project's Gruntfile, add a section named sundown
to the data object passed into grunt.initConfig()
.
grunt.initConfig({
sundown: {
target: {
options: {
extensions: {
fenced_code: true
},
render_flags: {
skip_html: true
}
},
files: {
'output.html': ['input1.md', 'input2.md']
}
}
}
});
options: {
extensions: {
autolink: false,
fenced_code: false,
lax_html_blocks: false,
no_intra_emphasis: false,
space_headers: false,
strikethrough: false,
tables: false
},
render_flags: {
skip_html: false,
skip_style: false,
skip_images: false,
skip_links: false,
expand_tabs: false,
safelink: false,
toc: false,
hard_wrap: false,
use_xhtml: false,
escape: false
},
separator: '\n\n' // concat option for multiple files
}
You can try your luck on the Sundown homepage. Or check out some of the other wrappers.
I'm a full-stack developer, co-organizer of PHP Vancouver meetup, and winner of a Canadian Developer 30 under 30 award. I'm a huge Open Source advocate and contributor to a lot of projects in my community. When I am not sitting at a computer, I'm trying to perfect some other skill.