I tried to use gradle for transpiling Kotlin to Js. When I run the example from https://www.codeflow.site/fr/article/kotlin-javascript I got the error : Could not initia
It seems it is a problem with different Ktlin verion as explained in Building Kotlin projects with Gradle sometimes fails with NoClassDefFoundError
Yes, as many before have said, the problem is probably that you have a kotlin version mis-match. But how do you know what version of kotlin is installed?
To find out your version of kotlin: Settings -> Language & Frameworks -> Kotlin
Make sure that you change your kotlin version (in both build.gradle files!) to this exact number. In my case (above) it's 1.4.10
Good luck!
update your Version in your gradle.properties file. eg) kotlinVersion=1.3.72
Simplest solution:
Go to file -> project structure (ctrl+shift+alt+s) -> suggestions -> accept all the suggestions.
To answer the OP's quetion, you just need to accept the one with the kotlin version