Skip to content

Releases: davbeck/SimpleHTML

Release list

SimpleHTML 1.0.0

Choose a tag to compare

@davbeck davbeck released this 14 Oct 21:01

SimpleHTML's first stable release brings HTML parsing, attributed strings, and SwiftUI paragraph and list rendering together in a Swift package.

Highlights

  • Display HTML with HTMLView, or render Markdown and other attributed text with BlockTextView.
  • Render paragraphs, nested ordered and unordered lists, and continuation paragraphs with SwiftUI text styling, alignment, and scaled spacing.
  • Convert HTML to Swift AttributedString with inline formatting, links, block presentation intents, and configurable whitespace preservation.
  • Inspect each text run's HTML element, source attributes, and ancestry to implement app-specific styling and media rendering.
  • Use HTMLParser delegate callbacks for custom parsing, or inspect HTMLAttributedStringBuilder.parseErrors for diagnostics.
  • Browse the included DocC API references and examples for custom emoji, images, YouTube embeds, and custom parsers.

Requirements

  • Swift 6.2 or newer
  • iOS 15 or macOS 12 or newer
  • System-provided libxml2; no separate runtime installation

Installation

Add https://github.com/davbeck/SimpleHTML in Xcode's File > Add Package Dependencies… and select version 1.0.0 or later, or add it to Package.swift:

.package(url: "https://github.com/davbeck/SimpleHTML", from: "1.0.0")

Link the SimpleHTML product to your target. See the README for usage and scope, and the DocC catalog for customization examples.

Validation

  • 82 test cases passed in Xcode on macOS 27.0.1.
  • 74 test cases passed on an iPhone 17 simulator running iOS 26.5.
  • The optimized Swift package build succeeded.
  • DocC conversion succeeded with warnings treated as errors.