Skip to content

0.11.0

Latest
Compare
Choose a tag to compare
@RandomHashTags RandomHashTags released this 05 Dec 15:33
· 7 commits to main since this release

Bug fix update by @RandomHashTags

Fixes

  • non-global attribute values not being HTML escaped (commit)
  • triple backslash quotation marks not being HTML escaped properly (commit)
  • missing attribute value when rendering if the key was wrapped in the "`" character (affected attributes: as, for, default, defer)
  • using interpolation in a multi-line context not being compiled correctly (commit, commit)
  • html expansion with encodings other than string produce the wrong result (it didn't account for how the string delimiter should be represented) (#3)
  • certain syntax combinations missing their expected content when being expanded into interpolation, and causing SourceKit and swift-frontend to get stuck in infinite loops (#5, #6)
  • escapeHTML macro not accounting for other HTMLEncodings (commit)

Breaking changes

  • changed the htmlValue computed property to func htmlValue(encoding:) for HTMLInitializable (commit)

Additions

  • Literal expansion logic for the html macro is now publicly available through HTMLKitUtilities.expandHTMLMacro (commit)
  • encoding parameter to the #escapeHTML macro. Default is string and, if contained in a #html macro, the parent encoding (commit)
  • CONTRIBUTING.md
  • .swift-format.json

Thanks

A special thanks to @andrebraga for reporting bugs that were fixed in this release!

Full Changelog: 0.10.0...0.11.0