A iOS API I am interested about is not available v...
# compose-ios
a
A iOS API I am interested about is not available via kotlin multiplatform. Is there a way to write it in Swift and use the class from kotlin in an Compose Multiplatform app?
google 1
m
You can transform your Swift code on an XCFramework containing a Header file (.h) and then you can use cinterop from KMP to access it
another option is to rewrite your Swift library in Kotlin Native (iOS target)
1
a
figured it out. Turns out I can use Kotlin code from Swift in my Compose app. had to
import ComposeApp
and rebuild the project on xcode, otherwise xcode doesnt pick it up
👍 2