Hello, so far KMP for desktop target application w...
# multiplatform
r
Hello, so far KMP for desktop target application work for me. But once I try wasmJs target, all hell brake lose. For instance, I started from scratch. As soon I include this library for example (https://github.com/sksamuel/hoplite) I get flooded with this kind of error:
Copy code
- Variant 'sourcesElements' capability com.sksamuel.hoplite:hoplite-core:2.7.5 declares a component for use during runtime:
           - Incompatible because this component declares documentation and the consumer needed a library
           - Other compatible attributes:
               - Doesn't say anything about its target Java environment (preferred optimized for non-jvm)
               - Doesn't say anything about org.jetbrains.kotlin.platform.type (required 'wasm')
               - Doesn't say anything about org.jetbrains.kotlin.wasm.target (required 'js')
e
unsurprising, as that library is JVM-only
1
r
Oh ok. I do you know? I'm still new to kotlin/jvm stuff
I taught that the whole point of KMP was to convert kotlin and/or java bytecode to wasm or something like that
e
Kotlin multiplatform is able to compile Kotlin code to other platforms and use interoperate with native libraries directly. it does not convert any existing Java bytecode
r
Oh ok
e
you can see in https://repo1.maven.org/maven2/com/sksamuel/hoplite/hoplite-core/2.7.5/hoplite-core-2.7.5.module that only JVM is present in their publication (but also that's basically what the Gradle error is saying)
r
I really taught it was a kind of AOT compiler