Skip to content

Commit 77be59a

Browse files
authored
Fix: Build save-common for JS target (#306)
### What's done: * Enable JS conditionally in the kotlin-library.gradle.kts
1 parent 24c2680 commit 77be59a

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

buildSrc/src/main/kotlin/org/cqfn/save/buildutils/kotlin-library.gradle.kts

+5
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ kotlin {
2727
}
2828
}
2929
val nativeTargets = listOf(linuxX64(), mingwX64(), macosX64())
30+
if (project.name == "save-common") {
31+
// additionally, save-common should be available for JS too
32+
// fixme: shouldn't rely on hardcoded project name here
33+
js(BOTH).browser()
34+
}
3035

3136
if (hasProperty("disableRedundantTargets") && (property("disableRedundantTargets") as String?) != "false") {
3237
// with this flag we exclude targets that are present on multiple OS to speed up build

save-common/build.gradle.kts

-3
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@ plugins {
33
}
44

55
kotlin {
6-
// additionally, save-common should be available for JS too
7-
js(BOTH).browser()
8-
96
sourceSets {
107
val commonMain by getting {
118
dependencies {

0 commit comments

Comments
 (0)