:exclamation::exclamation:Quick reminder:exclamation::exclamation: For the best experience with IR b...
i
Quick reminder For the best experience with IR backend, we are running a series of questions regarding per module generation. Please, don’t hesitate, follow the link and answer the questions, which will help us to make it better for you
a
I am having
Copy code
js(IR) {
        browser {  }
        compilations.all {
            kotlinOptions.freeCompilerArgs += listOf("-Xir-per-module")
        }
        binaries.executable() // binaries.library()
    }
In my
build.gradle.kts
but I can't seem to find the seperate module files. This is an
umbrella
module, depending on approximately 12 gradle subprojects. I checked my
build/compileSync/main/developmentExecutable/kotlin
I just found a
.d.ts
,
.js
and a
.map
. Where are the multiple modules being generated?
b
Hah, I faced the same issue. Turns out that flag only works when set on task, not extension
i.e.
Copy code
tasks.withType<KotlinCompile>{kotlinOptions.freeCompilerArgs += listOf("-Xir-per-module")}
Here's an example setup
a
I see. Thanks @Big Chungus