plugins {
...
kotlin("js") version "1.6.10"
id("com.google.devtools.ksp") version "1.6.10-1.0.2"
}
it gives me this error:
Copy code
You already registered Kotlin/JS target with another compiler: legacy
Googling indicates that ksp does support IR, I think? What am I doing wrong?
j
Jiaxiang
01/25/2022, 10:49 PM
KSP does support IR, the error message looks like some other build config issues? do you have the full picture of the build script?
j
jeff
01/29/2022, 5:08 PM
Here is my full build.gradle.kts:
Copy code
plugins {
kotlin("js") version "1.6.10"
id("com.google.devtools.ksp") version "1.6.10-1.0.2"
}
group = "com.example"
version = "1.0-SNAPSHOT"
repositories {
mavenCentral()
}
dependencies {
implementation("io.arrow-kt:arrow-optics:1.0.2-alpha.42")
// ksp("io.arrow-kt:arrow-optics-ksp-plugin:1.0.2-alpha.42")
implementation(kotlin("stdlib-js"))
testImplementation(kotlin("test"))
}
kotlin {
js(IR) {
binaries.executable()
nodejs {}
}
}
And here is the error, which points at the
js(IR)
line:
Copy code
You already registered Kotlin/JS target with another compiler: legacy
jeff
01/29/2022, 5:09 PM
(commenting out the ksp plugin removes this error)
j
Jiaxiang
01/31/2022, 9:37 PM
Thanks, I’ll take a look maybe tomorrow
j
jeff
02/01/2022, 8:08 PM
On the advice of someone in #javascript I tried switching to a multiplatform project, and that seems to have solved the IR/LEGACY issue. But, now I'm seeing this other issue.