Yan Pujante
11/10/2020, 10:46 PMkotlin {
js(IR) {
browser {
binaries.executable()
webpackTask {
cssSupport.enabled = true
}
runTask {
cssSupport.enabled = true
}
}
}
}
When I run the build
target it builds and put the result under <buildDir>/distributions
. I obviously can use File(buildDir, "distributions")
to access this folder, but I am sure there is some magic variable to get to it. And I suppose my second question/frustration is how on earth can you discover this kind of things without having to ask around in the slack channel? Although I am a big fan of gradle in general, I find it so not discoverable...Robert Jaros
11/10/2020, 10:59 PMturansky
11/10/2020, 11:00 PMdistributions
val distributions = tasks.getByName<KotlinWebpack>("browserDistribution").destinationDirectory!!
turansky
11/10/2020, 11:02 PMYan Pujante
11/10/2020, 11:05 PM* What went wrong:
Element 'browserDistribution' of type 'org.gradle.api.DefaultTask_Decorated' from container 'task set' cannot be cast to 'org.jetbrains.kotlin.gradle.targets.js.webpack.KotlinWebpack'.
turansky
11/10/2020, 11:06 PMval distributions = tasks.getByName<KotlinWebpack>("browserProductionWebpack").destinationDirectory!!
Yan Pujante
11/10/2020, 11:07 PMturansky
11/10/2020, 11:07 PMturansky
11/10/2020, 11:08 PMturansky
11/10/2020, 11:08 PMbuild
and kotlin browser
- most used groupsYan Pujante
11/10/2020, 11:09 PMturansky
11/10/2020, 11:10 PMYan Pujante
11/10/2020, 11:10 PM