https://kotlinlang.org logo
#javascript
Title
# javascript
p

Pierre

11/22/2023, 7:16 AM
Hi all, In one of our projects which is building a JS browser execuytable, we are migrating from using css to using scss. The main scss file is pulled into the build by use
require("web/sass/index.scss")
in the main Kotlin file. The index.scss file is pulling-in other scss partials via @use directives. The build is working correctly except that the webpack task is not triggered when one of the
_xxx.scss
file is modified. We tried adding input file dependencies to the Webpack task in our buildSrc gradle plugin like so:
Copy code
webpackTask {
    inputs.files(project.fileTree("${project.projectDir}/jsMain/web/sass") {
        include("**/*.scss")
    })
}
But unfortunately this has no effect. Any idea on how I can force re-running the webpack task?