Branded types and shared interfaces for the HTML/XML/RSS
generation bounded contexts. Branded types prevent accidental mixing of
raw strings with already-escaped or validated output.
These types are compile-time-only (erased by TypeScript) so they impose
zero runtime cost while catching misuse like passing unsanitized input
directly into an HTML template.
Description
Branded types and shared interfaces for the HTML/XML/RSS generation bounded contexts. Branded types prevent accidental mixing of raw strings with already-escaped or validated output.
These types are compile-time-only (erased by TypeScript) so they impose zero runtime cost while catching misuse like passing unsanitized input directly into an HTML template.