express-html-minify

html content minifier

Usage no npm install needed!

<script type="module">
  import expressHtmlMinify from 'https://cdn.skypack.dev/express-html-minify';
</script>

README

express-html-minify

A html-minifier middleware for expressjs

installation

npm install express-html-minify

usage


var express     = require('express');
var minify = require('express-html-minify');

var app = express();
app.use(minify);

app.get('/', function(req, res){
   res.header("content-type", 'text/html')
   res.sendfile(__dirname+"/index.html");
});

app.listen(8081);

LICENSE

BSD