Export KMP library to be used by native JS projects

Hello everyone.

How should I set up my build.gradle(:common) and what Gradle task should I use to be able to export my KMP library to be used by native JS or TS projects? Also, where in the folder structure will the output of this Gradle task be generated?

I have already successfully set up the JsExport annotation. The code for the JS part of the build.gradle(:common) is below. I have tried several combinations, but can’t get it right.

    js(IR) {
        compilations.all {
            compileKotlinTask.kotlinOptions.freeCompilerArgs += listOf("-opt-in=kotlin.RequiresOptIn")

Any help with this? :face_with_head_bandage:

Any help with this :frowning: