Is Androidx NavHost compatible with KMP?
# compose
s
Is Androidx NavHost compatible with KMP?
s
Nope.
p
Short answer no, the closest you have is a Library named PreCompose
s
For navigation you gotta go with something else. https://github.com/arkivanov/Decompose https://github.com/adrielcafe/voyager https://github.com/bumble-tech/appyx https://github.com/slackhq/circuit are the ones I am familiar with, pick one and try it out 😄
p
Those are the most popular ones but the closest in API design is PreCompose, basically a clone of jetpack compose
s
Oh and I remembered this https://github.com/xxfast/Decompose-Router also exists, as a library on top of Decompose. But cool to see PreCompose too, it does look similar to the Androidx one, that’s interesting
K 1
p
Yeap , an API clone pretty much. Although Voyager has some common design too. Decompose and Appyx have a different API layout so is circuit
yes black 1
s
compose-destinations is not KMP, it uses androidx.navigation and is just built on top of it. reimagined doesn’t seem to be KMP either.
👆 1
⚠️ 2
i
Star the issue if you'd like to see KMP support: https://issuetracker.google.com/issues/281774647
🌟 10