Package-level declarations

Types

Link copied to clipboard
@Serializable
data class ImportMap(val imports: Map<String, String> = emptyMap, val scopes: Map<String, Map<String, String>> = emptyMap(), val integrity: Map<String, String> = emptyMap)

An importmap definition.

Link copied to clipboard

Global configuration for HTML extension functions.

Properties

Link copied to clipboard

Determines whether the script function should set the type to module by default. You need modules if you are using import statements and import maps.

Link copied to clipboard

Determines whether the subresource integrity attribute should be set by default, when calling the convenience script and stylesheet functions.

Functions

Link copied to clipboard
fun FlowOrMetaDataOrPhrasingContent.importMap(importMap: ImportMap)

Adds a <script type="importmap"> tag for the given ImportMap.

fun FlowOrMetaDataOrPhrasingContent.importMap(vararg files: RevisionedFile, integrity: Boolean = RevFileHtml.useSubresourceIntegrity)

Adds a <script type="importmap"> tag for the given revisioned files.

Link copied to clipboard
fun FlowOrMetaDataOrPhrasingContent.script(file: RevisionedFile, crossorigin: ScriptCrossorigin? = null, integrity: Boolean = RevFileHtml.useSubresourceIntegrity, module: Boolean = RevFileHtml.useJsModules, block: SCRIPT.() -> Unit = {})

Adds a <script> tag for the given revisioned file.

Link copied to clipboard
fun HEAD.stylesheet(file: RevisionedFile, crossorigin: ScriptCrossorigin? = null, integrity: Boolean = RevFileHtml.useSubresourceIntegrity, block: LINK.() -> Unit = {})

Adds a <link rel="stylesheet"> tag for the given revisioned file.