An HTML builder is a type-safe Kotlin DSL for declaring an HTML document or fragment as a nested object hierarchy. Tags are ordinary functions receiving lambdas with receivers, so the receiver type controls which tags are available at each nesting level. section 13.2.2
A nested table declaration
fun createSimpleTable() = createHTML().table { tr { td { +"cell" } } } Here, table exposes tr, tr exposes td, and unary plus adds text to the surrounding cell. The API therefore mirrors HTML grammar while remaining regular Kotlin code. section 13.2.2
