gulp-prettify

Prettify, format, beautify HTML.

gulp-prettify

Prettify HTML.

Install the module with: npm install gulp-prettify

var gulp = require('gulp');
var prettify = require('gulp-prettify');
 
gulp.task('prettify', function() {
  gulp.src('src/*.html')
    .pipe(prettify({indent_size: 2}))
    .pipe(gulp.dest('dist'))
});

Other examples are in the example folder.

See the js-beautify docs for options.

In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality.

Copyright (c) 2014 Jon Schlinkert Licensed under the MIT license.