Skip to content

Commit 99b267c

Browse files
committed
fix(android): only apply Kotlin plugin if not using built-in
1 parent 655624c commit 99b267c

2 files changed

Lines changed: 10 additions & 4 deletions

File tree

packages/app/android/app/build.gradle

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,13 @@ buildscript {
77

88
plugins {
99
id("com.android.application")
10-
id("org.jetbrains.kotlin.android")
10+
id("org.jetbrains.kotlin.android") apply false
11+
}
12+
13+
// Only apply Kotlin plugin if `android.builtInKotlin=false`
14+
// https://developer.android.com/build/migrate-to-built-in-kotlin#enable-built-in-kotlin
15+
if (toVersionNumber(gradle.gradleVersion) < v(9, 4, 0) || project.findProperty("android.builtInKotlin") == false) {
16+
apply(plugin: "org.jetbrains.kotlin.android")
1117
}
1218

1319
// `react-native run-android` is hard-coded to look for the output APK at a very

yarn.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15226,9 +15226,9 @@ __metadata:
1522615226
linkType: hard
1522715227

1522815228
"undici@npm:^6.19.5, undici@npm:^6.21.3":
15229-
version: 6.24.1
15230-
resolution: "undici@npm:6.24.1"
15231-
checksum: 10c0/53fdbaa357139a2c12deed34f67d67fc6ad269630ba85a1507e7717f53ad2d3a02c95fbd17d3ab321e34c60b6f0a716cdc2f7e2eca1e07178702dc89cc3a73c4
15229+
version: 6.27.0
15230+
resolution: "undici@npm:6.27.0"
15231+
checksum: 10c0/f88c3dae3957dbf9d93cb481440aced317bd3c4941b5914fea5efba516d51138988cdb5c76006f0bb1337e41d56c3443351055d492e73af2428521c37ba2a76f
1523215232
languageName: node
1523315233
linkType: hard
1523415234

0 commit comments

Comments
 (0)