for some reason I can't get the gradle tasks to ge...
# compose-web
a
for some reason I can't get the gradle tasks to generate the full output needed for a compose web app I run
jsBrowserDistribution
or
jsBrowserDevelopmentExecutableDistribution
and it outputs a
composeApp.js
file, but no index or skiko etc. any ideas how to debug this?
My gradle config looks like this:
Copy code
js {
        browser {
            commonWebpackConfig {
                outputFileName = "composeApp.js"
                val rootDirPath = project.rootDir.path
                val projectDirPath = project.projectDir.path
                outputPath = File("$rootDirPath/dist/composeUnstyledDemos")
                devServer = (devServer ?: KotlinWebpackConfig.DevServer()).apply {
                    static = (static ?: mutableListOf()).apply {
                        // Serve sources to debug inside browser
                        add(rootDirPath)
                        add(projectDirPath)
                    }
                }
            }
        }
        binaries.executable()
    }
o
afair, the problem (bug) is the custom outputPath.
a
solved it by adding a distribution block:
Copy code
distribution {
                outputDirectory = File("$rootDirPath/dist/${project.name}")
            }
👍 2