I was kind of hoping there would be more discussio...
# google-io
d
I was kind of hoping there would be more discussion about Kotlin multi platform at Google IO, think I've seen it only mentioned once so far in the Kotlin in last 2 years session. I think getting people into it would help keep the eco system into more high quality native apps and move against everything becoming react native
m
Roman Elizarov claims that Jetpack Compose will be MPP lib (if the future at least)
And Jetpack Compose is a big thing for Android (and maybe even bigger for MPP)
d
Really? Was it during the compose session I watched that and don't remember them saying that
Although, you're right, they didn't say it on any sessions I watched
g
No, they do not mention it yet, it on too early stage for now. But there are comments in source code about separation of business logic from platform APIs in Canvas class
m
So, assuming business logic is pure Kotlin, adding platform-specific draws and user input would cover the basics for MPP lib?
r
I haven't looked at Compose at all yet, but just to note, separating business logic from platform APIs is also important for pure-Android codebases so unit tests can run on JVM instead of on-device. Even in a non-Multiplatform world there's good reason for Compose to have that separation, since this has been a pain point for Android APIs in the past.
m
^ yeah, it takes 5s for robolectric to warm up during unit tests
e
Compose is in the open and it is in Kotlin. It is simply too easy to make it MPP now. It is not the focus for compose team at the moment, but if not them, then somebody would port it other platforms eventually.
Compose team’s focus now is to bring new modern and easy to use UI toolkit for Android devs. That is what they were talking about. It was a great talk and solid rationale.
g
Totally, I can’t wait for an alpha on Android, and it could totally become the UI toolkit for Kotlin Multiplatform projects!
m
And if anyone is planning on adding multiplatform support, hit me up, I'd like to help
d
You could call it Kompose but something's already called that so, KKompose