@apply_to_text_file
def html5lib_minify(data):
 import html5lib
 import html5lib.serializer
 data = html5lib.serializer.serialize(html5lib.parse(data, treebuilder='lxml'), tree='lxml', quote_attr_values=False, omit_optional_tags=True, minimize_boolean_attributes=True, strip_whitespace=True, alphabetical_attributes=True, escape_lt_in_attrs=True)
 return data

@ apply_to_text_file def html5lib_minify ( data ) : import html5lib import html5lib . serializer data = html5lib . serializer . serialize ( html5lib . parse ( data , treebuilder = 'lxml' ) , tree = 'lxml' , quote_attr_values = False , omit_optional_tags = True , minimize_boolean_attributes = True , strip_whitespace = True , alphabetical_attributes = True , escape_lt_in_attrs = True ) return data
minify with html5lib .