minify-html/rust/onepass
Michael Pfaff b77eff39e1
Implement Display for Error and derive Clone for ErrorType
2023-05-15 00:13:36 -04:00
..
src Implement Display for Error and derive Clone for ErrorType 2023-05-15 00:13:36 -04:00
.gitignore Restructure Rust project 2021-08-08 17:40:42 +10:00
Cargo.toml 0.11.1 2023-05-07 19:34:04 +07:00
README.md 0.11.1 2023-05-07 19:34:04 +07:00

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

Usage

The API is different compared to minify-html; refer to per-package documentation for more details.

If you don't see your preferred language here and the main library supports it, raise an issue.

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.