Git Product home page Git Product logo

gulp-html-minify's Introduction

gulp-html-minify

NPM version Build Status Coverage Status

A simple gulp plugin, used to compressed html

Install

npm install gulp-html-minify

Usage

var htmlminify = require("gulp-html-minify");
gulp.task('build-html' , function(){
    return gulp.src("./html-init/**/*.html")
        .pipe(htmlminify())
        .pipe(gulp.dest("./html"))
});

Running Test

make test

License

MIT

gulp-html-minify's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

lifest99

gulp-html-minify's Issues

the plugin run error

TypeError: Cannot read property 'contents' of undefined,
The source file line 63

return through.obj(_transform());

replace

return through.obj(_transform);

Delete of line leads to html syntax error

Hi whxaxes,

I tried your minify plugin and I have one issue. For some angular directive I use this formating of HTML for better readability.

<app-footer
    footer="footer"
    hotspot="appData.hotspot"
    brand="appData.brand"
    cobrand="appData.cobrand"
    >
</app-footer>

But when it is minified, the output is:

<app-footerfooter="footer"hotspot="appData.hotspot"brand="appData.brand"cobrand="appData.cobrand"></app-footer>

And from directive app-footer is app-footerfooter

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.