Skip to content

2.0.0

Compare
Choose a tag to compare
@wooorm wooorm released this 03 Jul 10:45
· 180 commits to main since this release
Rewrite algorithm
Changes
  • Output less entities in places where they aren’t needed
Features
  • quote — Preferred attribute quote to use
  • quoteSmart — Use other quote if shorter
  • preferUnquoted — Use no quotes if shorter
  • omitOptionalTags
  • collapseEmptyAttributes
  • tightSelfClosing — No space before slash in void elements
  • tightCommaSeparatedLists
  • tightAttributes — No space between quoted attributes
  • allowParseErrors — Smaller size by allowing parse errors
  • allowDangerousCharacters — Smaller size by opening up XSS vectors
Bugs
  • Fix stringification of numeric data attribute (data-123 instead of data123)
Refactor
  • Refactor code-style
  • Rewrite tests
  • Remove superfluous dot-files