Skip to main content

0.8.0

New features

Support for custom Swift wrappers

Starting from this release, you can use SKIE to bundle manually written Swift code directly into the generated Kotlin framework.

This feature's primary intended use case is to allow KMP developers to write custom Swift wrappers for their Kotlin API. These wrappers allow you to better work around the remaining limitations of the Kotlin/Swift interop that SKIE currently does not solve automatically.

The main advantage of bundling the wrappers directly into the Kotlin framework is that you can keep the entire API in a single Framework. Having only a single Framework simplifies the distribution process and makes using and maintaining the Kotlin API easier.

The distribution process is simplified because you need to distribute only a single Kotlin framework (instead of distributing two or modifying the code in the Swift repository). Also, the bundled Swift code is easier to keep in sync with the Kotlin code because it is compiled together with the Kotlin code.

Read more about Swift Code Bundling.

Support for consuming Flows in SwiftUI

We've added a preview API for observing Flows in SwiftUI views. These APIs allow you to collect Flows in SwiftUI views and display the latest values in a way intuitive to SwiftUI developers.

Please note that this feature is still in preview, and we'd love to hear your feedback on it. Over the coming weeks we'll be extending this feature with more capabilities.

Read more about Flows in SwiftUI.

Support for Combine

We've also added a preview support for bridging Kotlin Coroutines with Apple's Combine framework. This allows you to use Kotlin Coroutines in Swift code that uses Combine.

Please note that this feature is also a preview, and your feedback is highly appreciated. Over the coming months we'll be gathering feedback and improving the feature based on it. We also plan to improve the test suite for this feature, before we bring it from preview to stable.

Read more about Combine support.

Improvements

  • Support for Kotlin 2.0.0