SMRTR ProgrammingJun 26, 2025Hacker News

The time is right for a DOM templating API

SMRTR summary

Templating: the missing piece of the web platform puzzle. Despite powering complex applications like Photoshop, the DOM API lacks a crucial feature found in modern frameworks: declarative templating. This omission forces developers to rely on external libraries, impacting performance and security.

Justin Fagnani, a web platform advocate, argues it's time for change. "The web platform should adapt to meet such clearly demonstrated developer needs," he says. Fagnani proposes a native templating API, leveraging JavaScript's tagged template literals to create and efficiently update DOM chunks.

The timing seems right. Frameworks have paved the way, demonstrating effective syntax and semantics. A native API could reduce app download times, simplify development, and level the playing field with native platforms.

While challenges remain, including potential integration with future JavaScript features like JSX, Fagnani sees a clear path forward. He envisions a system combining template identity and signals, offering speed, flexibility, and a foundation for future HTML-based templating.

SMRTR provides this summary for quick context. The original article belongs to Hacker News.

Read the original article
SMRTR Programming

Get the next batch of curated summaries in your inbox.

This archive is built from SMRTR newsletter summaries. Subscribe for hand-picked stories without the extra noise.