Skip to content

Commit 387a299

Browse files
committed
build(gradle): enable new feat for kotlin 2.2.20
1 parent 7964e87 commit 387a299

File tree

4 files changed

+10
-11
lines changed

4 files changed

+10
-11
lines changed

example/build.gradle.kts

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import com.android.build.gradle.internal.api.BaseVariantOutputImpl
77
import org.jetbrains.compose.desktop.application.dsl.TargetFormat
88
import org.jetbrains.kotlin.gradle.ExperimentalWasmDsl
9-
import org.jetbrains.kotlin.gradle.targets.js.webpack.KotlinWebpackConfig
109
import org.jetbrains.kotlin.gradle.targets.js.yarn.YarnPlugin
1110
import org.jetbrains.kotlin.gradle.targets.js.yarn.YarnRootExtension
1211
import java.util.Properties
@@ -70,24 +69,19 @@ kotlin {
7069
outputFileName = "composeApp.js"
7170
}
7271
}
72+
compilerOptions {
73+
freeCompilerArgs.add("-Xes-long-as-bigint")
74+
freeCompilerArgs.add("-XXLanguage:+JsAllowLongInExportedDeclarations")
75+
}
7376
binaries.executable()
7477
}
7578

7679
@OptIn(ExperimentalWasmDsl::class)
7780
wasmJs {
7881
outputModuleName.set("composeApp")
7982
browser {
80-
val rootDirPath = project.rootDir.path
81-
val projectDirPath = project.projectDir.path
8283
commonWebpackConfig {
8384
outputFileName = "composeApp.js"
84-
devServer = (devServer ?: KotlinWebpackConfig.DevServer()).apply {
85-
static = (static ?: mutableListOf()).apply {
86-
// Serve sources to debug inside browser
87-
add(rootDirPath)
88-
add(projectDirPath)
89-
}
90-
}
9185
}
9286
}
9387
binaries.executable()

gradle.properties

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ kotlin.code.style=official
1616
kotlin.mpp.androidSourceSetLayoutVersion=2
1717
kotlin.mpp.enableCInteropCommonization=true
1818
# Native
19+
kotlin.native.binary.smallBinary=true
1920
kotlin.native.ignoreDisabledTargets=true
2021
# Incremental compilation
2122
kotlin.incremental=true

iosApp/iosApp/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<key>CFBundleShortVersionString</key>
1818
<string>1.0.4</string>
1919
<key>CFBundleVersion</key>
20-
<string>549</string>
20+
<string>550</string>
2121
<key>LSRequiresIPhoneOS</key>
2222
<true/>
2323
<key>CADisableMinimumFrameDurationOnPhone</key>

miuix/build.gradle.kts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ kotlin {
5151

5252
js(IR) {
5353
browser()
54+
compilerOptions {
55+
freeCompilerArgs.add("-Xes-long-as-bigint")
56+
freeCompilerArgs.add("-XXLanguage:+JsAllowLongInExportedDeclarations")
57+
}
5458
}
5559

5660
sourceSets {

0 commit comments

Comments
 (0)