Hi, if I create a kmm library from kmm plugin inside my existing android project , can I implement ...
r
Hi, if I create a kmm library from kmm plugin inside my existing android project , can I implement that library in ios project which was not created from kmm plugin , basically will I able to implement the kmm library into existing ios project , Any one ?
j
An existing iOS project can consume a Kotlin Multiplatform library, yes. You just need to export the library as an Objective-C framework and use it in the iOS app. You can connect the iOS project to build the framework from the shared module or use the CocoaPods plugin.
r
Thanks, one more have you tried creating multi-platform library using intellij ,also if I only Target ios and android in intellij it will be consider stable right ?
j
Yes, but right now it's easier to create projects in Android Studio with the KMM plugin. There is an IntelliJ KMM plugin, but it's still in early-bird testing. Once you've created a project, you can open it in IntelliJ just fine. Or you can manually create the multiplatform modules and build files as well. I'm targeting JVM, Android, iOS, macOS, and JS in codebases I consider stable and other native targets that are just less tested. There are many others successfully deploying KMP in production to various targets. In general, it's mostly the KMP tooling that's still incomplete (like these IDE plugins). KMP code itself is stable. There are just some APIs that may potentially change in the future (they're marked as such in Kotlin 1.9). You can see the stability of individual components here.
r
Thanks for your info