![]() |
||
---|---|---|
.. | ||
src | ||
.gitignore | ||
Cargo.toml | ||
README.md |
README.md
minify-html-onepass
An HTML minifier that provides the functionality of minify-html with much more performance, but with stricter parsing and less configurability.
- Uses the same advanced minification strategy.
- Minifies in one pass with zero memory allocations.
- Outputs in place; no copy or buffer required.
Performance
![Chart showing speed of HTML minifiers](https://wilsonl.in/minify-html/bench/0.8.1/core/average-speeds.png)
Usage
The API is different compared to minify-html; refer to per-package documentation for more details.
in.wilsonl.minifyhtmlonepass
@minify-html/onepass
minify-html-onepass
minify_html_onepass
minify-html-onepass
Parsing
In addition to the minify-html rules, the onepass variant has additional requirements:
- Opening tags must not be omitted.
- Invalid closing tags are not allowed.
- The document cannot end unexpectedly.