66 lines
1.9 KiB
Plaintext
66 lines
1.9 KiB
Plaintext
import org.jetbrains.compose.desktop.application.dsl.TargetFormat
|
|
import org.jetbrains.kotlin.gradle.ExperimentalWasmDsl
|
|
|
|
plugins {
|
|
alias(libs.plugins.kotlin.multiplatform)
|
|
alias(libs.plugins.kotlin.serialization)
|
|
alias(libs.plugins.compose.multiplatform)
|
|
alias(libs.plugins.compose.compiler)
|
|
}
|
|
|
|
kotlin {
|
|
jvm()
|
|
|
|
@OptIn(ExperimentalWasmDsl::class)
|
|
wasmJs {
|
|
browser {
|
|
commonWebpackConfig {
|
|
outputFileName = "composeApp.js"
|
|
}
|
|
}
|
|
binaries.executable()
|
|
}
|
|
|
|
sourceSets {
|
|
commonMain.dependencies {
|
|
implementation(compose.runtime)
|
|
implementation(compose.foundation)
|
|
implementation(compose.material3)
|
|
implementation(compose.ui)
|
|
implementation(compose.components.resources)
|
|
implementation(compose.components.uiToolingPreview)
|
|
|
|
// HTTP client dependencies for ping-service
|
|
implementation(libs.ktor.client.core)
|
|
implementation(libs.ktor.client.contentNegotiation)
|
|
implementation(libs.ktor.client.serialization.kotlinx.json)
|
|
implementation(libs.kotlinx.coroutines.core)
|
|
implementation(libs.kotlinx.serialization.json)
|
|
}
|
|
commonTest.dependencies {
|
|
implementation(libs.kotlin.test)
|
|
}
|
|
jvmMain.dependencies {
|
|
implementation(compose.desktop.currentOs)
|
|
implementation(libs.kotlinx.coroutines.swing)
|
|
implementation(libs.ktor.client.cio)
|
|
}
|
|
wasmJsMain.dependencies {
|
|
implementation(libs.ktor.client.js)
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
compose.desktop {
|
|
application {
|
|
mainClass = "at.mocode.MainKt"
|
|
|
|
nativeDistributions {
|
|
targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb)
|
|
packageName = "at.mocode"
|
|
packageVersion = "1.0.0"
|
|
}
|
|
}
|
|
}
|