#KotlinJS_Gradle [SOLVED:white_check_mark:] we hav...
# javascript
b
#KotlinJS_Gradle [SOLVED] we have kotlinJS project act as a library module for others kotlinJS projects we were able to migrate this project to use the KotlinJs gradle plugin by following the newly added docs and the project compiles successfully with no issues but now we are trying to use this project as a module for the other projects (which they also migrated) the problem happens in the
"ourLibraryModule":browserWebpack
task it fails for some dependencies (kotlin-react, kotlin-react-dom, kotlin-extensions, kotlinx-html-js) with the known error message “Module not found: Error: Can’t resolve etc.” we had this issue before when we tried to manage our projects using the kotlin frontend plugin but in the end we end up giving up on that some lines of code states how we doing this right now : in ourModule
build.gradle
Copy code
sourceSets["main"].dependencies{
    api(npm("kotlinx-html","0.6.12"))
    api(npm("@jetbrains/kotlin-extensions","1.0.1-pre.89"))
    api(npm("@jetbrains/kotlin-react", "16.9.0-pre.83"))
    api(npm("@jetbrains/kotlin-react-dom", "16.9.0-pre.83"))
    }
in parent
build.gradle
Copy code
dependencies {
    implementation(kotlin("stdlib-js"))
    implementation(project(":ourModule"))
}
in ourModule
build.gradle
we have other dependencies but the webpack task fails only for those does anyone has this project setup and were able to do it by gradle ?
Solved by Using the mentioned dependencies from jcenter instead of npm