https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
n

neerav

03/22/2024, 2:41 PM
Hello, Trying library for Navigation for multiplatform inlcuding web & desktop . But getting below error with context like not found non-jvm Library : PreCompose (tried
1.6.0-beta01 to 1.6.0-rc04
) Can anyone please help me or guide to resolve this ? Same error i got for another library :
voyager
Copy code
Could not resolve all dependencies for configuration ':composeApp:wasmJsCompileClasspath'.
> Could not resolve moe.tlaster:precompose-molecule:1.6.0-beta01.
  Required by:
      project :composeApp
   > No matching variant of moe.tlaster:precompose-molecule:1.6.0-beta01 was found. The consumer was configured to find a library for use during 'kotlin-api', preferably optimized for non-jvm, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'wasm', attribute 'org.jetbrains.kotlin.wasm.target' with value 'js' but:
       - Variant 'debugApiElements-published' capability moe.tlaster:precompose-molecule:1.6.0-beta01 declares a library for use during compile-time:
           - Incompatible because this component declares a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm' and the consumer needed a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'wasm'
           - 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.wasm.target (required 'js')
p

Pablichjenkov

03/22/2024, 3:08 PM
Seems like a transitive dependency
precompose-molecule
doesn't support all your targets. Is complaining about
wasm
support missing in that library. If open source, open a ticket for them so they update it.
n

neerav

03/22/2024, 4:01 PM
Yes its fir wasm
s

SanjayKarki

03/28/2024, 7:59 AM
@neerav can you share the mainactivity screenshot
n

neerav

03/28/2024, 8:21 AM
its resolved now. Issue was wrong package artifact used :
moe.tlaster:precompose:1.6.0-rc05
4 Views