I'm following <https://kotlinlang.org/docs/js-proj...
# javascript
b
I'm following https://kotlinlang.org/docs/js-project-setup.html but see no compiled js file, are the docs outdated and how can I create a minimally working setup?
1
this is my build.gradle.kts
Copy code
import org.jetbrains.kotlin.gradle.targets.js.nodejs.NodeJsRootExtension
import org.jetbrains.kotlin.gradle.targets.js.nodejs.NodeJsRootPlugin

plugins {
    kotlin("multiplatform") version "1.9.23"
}

group = "at.posselt"
version = "0.0.1"

repositories {
    mavenCentral()
}

kotlin {
    js {
        browser {
            webpackTask {
                mainOutputFileName = "kjs.js"
                output.libraryTarget = "plain"
            }
        }
        binaries.executable()
    }
    sourceSets {
        commonTest.dependencies {
            implementation(kotlin("test"))
        }
    }
}

rootProject.plugins.withType<NodeJsRootPlugin> {
    rootProject.the<NodeJsRootExtension>().download = false
}

dependencies {
}
a
What gradle task do you run?
b
jsRun
a
with
jsRun
the webpack devserver run (so, no bundle will be generated). Try to run
jsBrowserDevelopmentWebpack
or
jsBrowserProductionWebpack
b
thanks, I also figured out that the directory names were wrong, got it working now, thanks!