HTML5 minify
HTML5 minifier implementation based on Servo's html5ever.
Features
- High performance
- Input using
AsRef<[u8]>
/io::Read
- Output to
Vec<u8>
/io::Write
Examples
use Minify;
// Using Minify trait on &str:
let html = "<html> \n<link href=\"test.css\">\n<h2 id=\"id_one\" >Hello\n</h2> \n<p>\nWorld</p>";
let minified = html.minify.expect;
// Using minifier with omit doctype option set:
let mut minified = vec!;
new
.omit_doctype
.minify
.expect;