Files
meldestelle/frontend/core/domain/build.gradle.kts
T
stefan 591f703015 refactor(build): centralize JVM toolchain configuration in root build.gradle.kts
Removed redundant `jvmToolchain(25)` declarations across module build scripts, as the JVM toolchain is now managed centrally. Added comments for clarity.
2026-01-03 12:52:01 +01:00

40 lines
917 B
Kotlin

@file:OptIn(ExperimentalKotlinGradlePluginApi::class)
import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
plugins {
alias(libs.plugins.kotlinMultiplatform)
alias(libs.plugins.kotlinSerialization)
}
kotlin {
// Toolchain is now handled centrally in the root build.gradle.kts
val enableWasm = providers.gradleProperty("enableWasm").orNull == "true"
jvm()
js {
browser {
testTask { enabled = false }
}
}
if (enableWasm) {
@OptIn(org.jetbrains.kotlin.gradle.ExperimentalWasmDsl::class)
wasmJs { browser() }
}
sourceSets {
commonMain.dependencies {
implementation(libs.kotlinx.serialization.json)
}
}
}
tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> {
compilerOptions {
jvmTarget.set(JvmTarget.JVM_25)
freeCompilerArgs.addAll("-opt-in=kotlin.RequiresOptIn")
}
}