gulp plugin to covert HTML to Jade format.
npm install gulp-html2jade> gulp plugin to HTML to jade format.
First, install gulp-html2jade as a development dependency:
``shell`
npm install --save-dev gulp-html2jade
Then, add it to your gulpfile.js:
Say our index.html is :
`html`
Hello Gnumanth
`javascript`
var html2jade = require('gulp-html2jade');
var options = {nspaces:2};
gulp.task('default', function(){
gulp.src('index.html')
.pipe(html2jade(options))
.pipe(gulp.dest('dist'));
});index.jade
Now dist will have with content as:
`jade``
html
body Hello Gnumanth
Read more about the options that you could use.