htmlcompressor
com.github.hazendaz
HtmlCompressor is a small, fast and very easy to use Java library that minifies given HTML or XML source by removing extra whitespaces, comments and other unneeded characters without breaking the content structure. As a result pages become smaller in size and load faster. A command-line version of the compressor is also available.
Add to your project2.0.1
<dependency>
<groupId>com.github.hazendaz</groupId>
<artifactId>htmlcompressor</artifactId>
<version>2.0.1</version>
</dependency>Version Details — 2.0.1
HtmlCompressor is a small, fast and very easy to use Java library that minifies given HTML or XML source by removing extra whitespaces, comments and other unneeded characters without breaking the content structure. As a result pages become smaller in size and load faster. A command-line version of the compressor is also available.