magnumrocha
12/05/2024, 1:36 PMIgor Demin
12/05/2024, 1:50 PMmagnumrocha
12/05/2024, 2:01 PMkotlinx-html
or Compose HTML
?Igor Demin
12/05/2024, 2:16 PMCompose HTML
is more heavyweight, but provides a different approach (reactive instead of imperative).
kotlinx-html
is just a convenient wrapper over the DOM API. It requires more boilerplate in complex applications.Md Sadique Inam
12/06/2024, 5:14 AMmagnumrocha
12/06/2024, 7:57 AMmagnumrocha
12/06/2024, 7:58 AMplugins {
kotlin("multiplatform")
kotlin("plugin.compose")
id("org.jetbrains.compose")
}
...
kotlin {
js {
browser {
commonWebpackConfig {
cssSupport {
enabled.set(true)
}
}
}
binaries.executable()
}
sourceSets {
jsMain.dependencies {
implementation(compose.html.core)
implementation(compose.runtime)
}
commonTest.dependencies {
implementation(kotlin("test"))
}
}
}