Skip to content
This repository has been archived by the owner on Nov 26, 2022. It is now read-only.

RubenVerborgh/HTML5small

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

59 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HTML5small

HTML5small is a general-purpose minifier for HTML5 documents.
It is faster than html_compressor and at the same time compresses much better, while still generating valid HTML5.

Usage

$ gem install html5small
require 'html5small'
::HTML5.minify '<html>...</html>'

As a nanoc filter

HTML5small can also be used as a nanoc filter. This will lead to even faster loading of your compiled sites.

To use the HTML5small filter, add this line to your lib/helpers.rb:

require 'html5small/nanoc'

Then adapt your Rules to apply the filter where necessary. For example:

compile '/blog/*/' do
  filter :erb
  filter :html5small
end

Origin

HTML5small is based on h5-min, which is currently unmaintained.

About

HTML5small is a general-purpose minifier for HTML5 documents.

Resources

License

Stars

Watchers

Forks

Packages

No packages published