If I use compose-desktop in macOS platform, how can I access macOS framework like PhotosKit to retrieve medias in current device?
r
romainguy
01/24/2021, 6:15 AM
You'd have to write JNI code to call into native APIs
👍 1
q
Qinghua
01/24/2021, 6:24 AM
Oh, I see. Thanks a lot. I found that examples in compose-jb repo use kotlin-native to interact with apple system but missing jetpack-compose-desktop. Is it possible in the future to use compose-UI in kotlin-native?
j
jim
01/24/2021, 2:26 PM
Not yet, Compose has some JVM dependencies so it can't be compiled via K/N at this time. But you can use JNI to call any native code, including KotlinNative code.