I have a Full stack project on kotlin multiplatfor...
# javascript
t
I have a Full stack project on kotlin multiplatform. One is jvm and other is js. jvm compiling is faster but js one is very slow. Any tips to fasten the compiling of kotlin/js codebase?
r
Use legacy backend instead of IR
Also disable source maps if using legacy
t
Copy code
js(LEGACY) {
  browser {
    binaries.executable()
    webpackTask {
      cssSupport.enabled = true
    }
    runTask {
      cssSupport.enabled = true
    }
    testTask {
      useKarma {
        useChromeHeadless()
        webpackConfig.cssSupport.enabled = true
      }
    }
  }
}
am still using legacy if this is the setting you are referring to. I don't see any source map setting in build.gradle file.
r
Copy code
runTask {
    sourceMaps = false
}
t
sourcemap setting did not helped. it is still slower than jvm. I will read more on this and github link you shared. Thank you.
a
Current JS compiler is not as fast as JVM compiler... We are stuck with that one for now
t
understood, thank you.