Suspend Functions as Swift async
Consume Kotlin coroutines from Swift concurrency.
Suspend, Meet async
A Kotlin suspend function is exposed to Swift as an async method, so iOS can await it with native Swift concurrency.
suspend fun loadUser(): UserNo Callbacks Needed
Older bridges forced completion handlers. Modern KMP maps suspend straight to async, so Swift code stays clean and linear.
All lessons in this course
- How Kotlin Maps to Objective-C
- Suspend Functions as Swift async
- Collect Flows from Swift
- @ObjCName & Swift-Friendly APIs