laravel-elixir-styledown
v1.0.0
Published
Laravel Elixir Styledown Extension
Downloads
5
Readme
Laravel Elixir Styledown
This Laravel Elixir extension allows you to compile styledown.
Installation
First, pull in the extension through NPM.
$ npm install --save-dev laravel-elixir-styledown
Next, add it to your Elixir-enhanced Gulpfile, like so:
var elixir = require('laravel-elixir');
require('laravel-elixir-styledown');
elixir(function(mix) {
mix.styledown('components/button.md');
});
Don't forget create a config.md and that's it! You're all set to go!
Usage
Assuming you write...
elixir(function(mix) {
mix.styledown('components/button.md');
});
...this will take resources/assets/styledown/config.md
as configuration and compile your resources/assets/styledown/components/button.md
file to ./public/styledown/styledown.html
.
If you'd like to set a different output directory, you may pass a second argument to the styledown()
method, like so:
mix.styledown('components/button.md', 'public/docs/button.html');
Finally, if you want to override the Styledown plugin options, you may pass an object as the third argument.
mix.styledown('components/button.md', 'public/docs/button.html', {});
// See options at: https://www.npmjs.com/package/gulp-styledown#options
Default Options
{
src: 'resources/assets/styledown', // Path to src files
config: 'resources/assets/styledown/config.md', // Path to config.md
filename: 'styledown.html', // output filename
dest: './public/styledown' // Path to output folder
}