diff --git a/build.gradle.kts b/build.gradle.kts index b477c414..36fec1be 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -4,6 +4,7 @@ import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.dsl.KotlinVersion import org.jetbrains.kotlin.gradle.targets.js.dsl.ExperimentalWasmDsl +import org.jetbrains.kotlin.gradle.tasks.KotlinCompile plugins { kotlin("multiplatform") version "2.0.0" @@ -33,6 +34,12 @@ repositories { google() } +tasks.withType<KotlinCompile> { + compilerOptions { + jvmTarget = JvmTarget.JVM_1_8 + } +} + kotlin { explicitApi() @@ -46,10 +53,6 @@ kotlin { } jvm { - @OptIn(ExperimentalKotlinGradlePluginApi::class) - compilerOptions { - jvmTarget = JvmTarget.JVM_1_8 - } } js { browser {