minify HTML responses like some crazy guy
JavaScript
Latest commit 56411d3 Jan 1, 2016 @jonathanong jonathanong Merge pull request #1 from koajs/greenkeeper-update-all
Update all dependencies 🌴
Permalink
Failed to load latest commit information.
test add coverage Sep 16, 2014
.gitignore add coverage Sep 16, 2014
.travis.yml add coverage Sep 16, 2014
LICENSE init Jun 13, 2014
README.md init Jun 13, 2014
index.js init Jun 13, 2014
package.json chore(package): update dependencies Jan 1, 2016

README.md

Koa HTML Minifier

Middleware that minifies your HTML responses using html-minifier. It uses html-minifier's default options which are all turned off by default, so you have to set the options otherwise it's not going to do anything.

API

// do compression stuff first
app.use(require('koa-compress')());

// then use this minifier
app.use(require('koa-html-minifier')({
  collapseWhitespace: true
}));

Options

See: https://github.com/kangax/html-minifier#options-quick-reference