I saw that in `androidx.lifecycle:lifecycle-common...
# compose-ios
b
I saw that in
androidx.lifecycle:lifecycle-common:2.8.0-alpha03
there's now Lifecycle stuff available for KMP. I can now see the
Lifecycle
items like
Lifecycle
,
LifecycleOwner
,
LifecycleEventObserver
in my common code. On Android I have
LocalLifeCycleOwner
to get the current LifecycleOwner but I don't have something like that in the iOS module? I tried adding
androidx.lifecycle:lifecycle-runtime:2.8.0-alpha03
in the iOS dependencies as well and no luck. What am i missing so I can get the LifecycleOwner on the iOS side?
i
It doesn't exist yet, even if you will get this var from some Google's alpha it won't be initialized. in Compose Multiplatform 1.6.10 it will be solved by handling OS events by compose itself and map it to lifecycle state
👍 1
b
Oh, well that explains it then. Is there a rough idea of how far out that would be?
i
Working on that, first dev will be soon (most likely in ~2w)
b
Awesome! I'll keep an eye on that. Thanks!
p
Can you also make the library available to Browser? When I throw the dependency in commonMain compiler complains about missing js target.
i
Yes, JetBrains will re-publish it for web targets too, it's already implemented
💯 4
🙌 6
p
Great to hear that 😃