Call Shared Code from the iOS App
Import the framework and call it from Swift.
Shared Code as a Framework
On iOS your Kotlin compiles into a framework. Swift consumes it just like any Apple library you import into a project.
Import the Framework
At the top of your Swift file you import the shared framework by its name, usually Shared. That single line unlocks every export.
import SharedAll lessons in this course
- A Greeting Function in commonMain
- Call Shared Code from the Android App
- Call Shared Code from the iOS App
- Change Once, See It on Both Apps