A walkthrough of integrating Compose Multiplatform with SwiftUI in the PeopleInSpace KMP sample app, specifically for the ISS position tracking screen. The approach layers SwiftUI for the outer shell and navigation, shared Compose Multiplatform code for the content area, and native map components (MapKit on iOS, osmdroid on Android). Key techniques include using UIViewControllerRepresentable to embed Compose in SwiftUI, Kotlin's expect/actual mechanism for platform-specific map views, UIKitViewController to embed SwiftUI components inside Compose, a shared Kotlin ViewModel passed across both layers, and the SKIE library to observe Kotlin StateFlows in SwiftUI.

4m read timeFrom johnoreilly.dev
Post cover image
Table of contents
OverviewImplementationRelated tweet
5 Impressions