https://kotlinlang.org logo
Title
c

Colton Idle

06/01/2021, 4:42 PM
3. I'm currently using
import androidx.compose.ui.util.lerp
in my android only compose module. But converting it to JB compose doesn't work because it can't find it. Am I missing some util dependency that's available or is lerp not available in JB compose?
OoooOh. I just added `
implementation("androidx.compose.ui:ui-util:1.0.0-beta07")
and lerp seems to be available again? Is it okay to mix and match JB compose and android compose?
i

Igor Demin

06/01/2021, 5:07 PM
Better to not mix them until we have a stable versions of both. Just add the JB version:
implementation(compose("orj.jetbrains.compose.ui:ui-util")
o

olonho

06/01/2021, 5:39 PM
Regarding 2. We do have desktop-only preview annotation, and maybe one could try to commonize it with some optional annotation.
c

Colton Idle

06/01/2021, 5:59 PM
Thank you both! It worked! I converted my android project to support a desktop applicaiton. I'll have more questions in the future because the 100+ composables I built already, do not actually work on desktop (using android R classes, custom fonts, coil image loader is not multiplatform) but for now I have a desktop module inside of my android application. HOORAY. THANK YOU SO MUCH!
🎉 1