HTMLMinifier is a highly configurable, well-tested, JavaScript-based HTML minifier. Minifier options like sortAttributes and sortClassName won't impact the plain-text size of the output. However, they form long repetitive chains of characters that should improve compression ratio of gzip used in HTTP compression. SVG tags are automatically recognized, and when they are minified, both case-sensitivity and closing slashes are preserved, regardless of the minification settings used for the rest of the file. HTMLMinifier can't work with invalid or partial chunks of markup. This is because it parses markup into a tree structure, then modifies it (removing anything that was specified for removal, ignoring anything that was specified to be ignored, etc.), then it creates a markup out of that tree and returns it.

Features

  • Case-sensitive
  • Attribute values from boolean attributes
  • Collapse inline tag whitespace
  • Decode entity characters
  • Insert tags generated by HTML parser
  • Keep the trailing slash on singleton elements

Project Samples

Project Activity

See All Activity >

Categories

HTML/XHTML

License

MIT License

Follow HTMLMinifier

HTMLMinifier Web Site

Other Useful Business Software
Time tracking software for the global workforce Icon
Time tracking software for the global workforce

Teams of all sizes and in various industries that want the best time tracking and employee monitoring solution.

It's easy with Hubstaff, a time-tracking and workforce management platform that automates almost every aspect of running or growing a business. Teams can track time to projects and to-dos using Hubstaff's desktop, web, or mobile applications. You'll be able to see how much time your team spends on different tasks, plus productivity metrics like activity rates and app usage through Hubstaff's online dashboard. Most of the available features are customizable on a per-user basis, so you can create the team management tool you need.
Learn More
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of HTMLMinifier!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript HTML XHTML

Registered

2021-12-10