I have a 1.7MB Kotlin/JS webpack bundle that loads...
# javascript
a
I have a 1.7MB Kotlin/JS webpack bundle that loads in ~4 seconds in Chrome but takes ~25 seconds in Safari (both dev and prod builds). I use
jsBrowserProductionWebpack
task to build it Is this Safari slowdown typical for Kotlin/JS? Any optimization tips or profiling suggestions?
Copy code
kotlin {
    js {
        outputModuleName.set("kmm")
        browser {
            webpackTask {
                output.library = "kmmLib"
            }
        }
    }
    sourceSets {
        val jsMain by getting {
            dependencies {
                implementation(npm("@js-joda/core", "6.0.1"))
                implementation(npm("@js-joda/timezone", "2.25.1"))
            }
        }
    }
}
e
I think a reproducer is essential here. Once it's there the Kotlin team can evaluate where Webkit is slowing down.
➕ 1
t
If it's bundler problem - you can use Vite instead.