Skip to main content

Release 2.1

· One min read
Miguel Gamboa
HtmlFlow Author

HtmlFlow version 2.1 is updated to release 1.0.10 of com.github.xmlet.HtmlApi and introduces a couple of new features:

  • A new render() method that produces a String rather than writing to a PrintStream. This uses a StringBuilder internally and offers better performance than the previous write() approach.
  • HtmlView<T> now extends AbstractElement<HtmlView<T>, Element> and is compatible with Element, allowing it to be a parent element of Html. However, it does not support accept(ElementVisitor visitor) or cloneElem().
  • The Html root field definition in HtmlView is updated to include the generic parent as Html<HtmlView> and add it as a child of that HtmlView.
  • A new static factory method html() is introduced to start building an HtmlView.
  • These features, combined with the existing º() method, make it possible to build a view in a single pass, reducing the need for auxiliary variables to capture intermediate elements. All views in the README.md examples are now built using static field assignments. More usage examples can be found in HtmlTables and HtmlLists.