htmlkotlinktorkotlin-dslkotlin-html-builder

Using "property" in HTML meta data with kotlin DSL


Hey how can i use html content like:

<meta property="og:locale" content="en"/>

with the Kotlin HTML Type Safe builder? I cannot find something like the property variable in the meta function


Solution

  • meta(content = "en") {
        attributes["property"] = "og:locale"
    }