Kotlin
A concise multiplatform language developed by JetBrains
Compose Multiplatform 1.6.10 – iOS Beta, Web Alpha, Lifecycle, Navigation, and More
Compose Multiplatform is a declarative UI framework built by JetBrains that allows developers to share UI implementations across different platforms. Compose Multiplatform unlocks full code-sharing flexibility for Kotlin Multiplatform projects, allowing you to write your apps in up to 100% Kotlin. The 1.6.10 release includes several powerful features, and upgrades iOS support to Beta and Web support to Alpha.
Get Started with Compose Multiplatform
The highlights of this release include:
- The multiplatform resources API is now stable and there are several long-awaited improvements to this library.
- The experimental navigation library based on Jetpack Compose Navigation.
- The common Lifecycle library, with a common ViewModel implementation.
- Kotlin 2.0.0 is supported with the use of the new Compose compiler Gradle plugin.
For further details on all notable changes, see What’s new in Compose Multiplatform 1.6.10. The comprehensive list of all version-to-version changes, updates, and fixes is available in the release notes on GitHub.
Table of Contents
Compose Multiplatform for iOS in Beta
Since entering the Alpha stage last year, Compose Multiplatform for iOS took great strides in improving its native look and feel.
These enhancements include:
- Interactions feel more natural thanks to new scroll physics as well as the native text fields, window insets, text selection, and magnifying tool.
- Popups, dialogs, and other widgets feel more organic.
- Compose rendering was adapted for ProMotion displays, supporting dynamic refresh rates up to 120 Hz.
- Support for iOS accessibility features – including VoiceOver, font and zoom preferences, and accessibility tree sync – was added.
- UI testing with the new common DSL is possible.
- And last but not least, several important Material 3 components were adapted for iOS:
DatePicker
,AlertDialog
,DropdownMenu
,ModalBottomSheet
, andSearchBar
.
Aiming at the Stable release, we’re working on performance improvements and fixing as many issues as possible with Compose components on iOS.
Compose Multiplatform for Web in Alpha
The Compose Multiplatform team is excited to announce that the experimental Web target is now in Alpha:
- Jetpack Compose functionality implemented for other platforms is available for Web, as well.
- The team is committed to bringing the web platform to release.
However, there is still a long way to go with the browser adaptation of most components. Stay tuned as we continue to improve Compose Multiplatform for Web! To try out a Compose web app, follow our tutorial.
Multiplatform resources
The resources library is now stable! Along with improved reliability, the API is now more flexible and convenient:
- You can organize resources in any modules and source sets that make sense to you. There’s no need to confine them to
commonMain
. Compose Multiplatform will take care of publishing the necessary files for each platform. Res
class generation can be controlled in the Gradle configuration file in thecompose.resources {}
block.- There are new experimental functions that allow fetching fonts and images as byte arrays. These should help third-party libraries that need access to multiplatform resources.
These and other changes are detailed in the updated documentation.
Experimental navigation library
Jetpack Compose Navigation approach has now been implemented in Compose Multiplatform. You can use navigation hosts, graphs, and controllers to help users move between screens with ease.
The common navigation library is still experimental but covers most of the core functionality. Look through the documentation to understand its current capabilities and limitations.
Lifecycle library and a common ViewModel
Based on Jetpack Lifecycle, the Lifecycle library provides a common LifecycleOwner
implementation, extends the original Jetpack Compose functionality to other platforms and helps observe lifecycle states in common code.
Along with state management, the common lifecycle
library includes a common ViewModel
implementation. You can now use the Android approach to building robust UIs on all platforms.
See the documentation for details on these APIs’ implementation and setup.
New Compose compiler Gradle plugin
The Compose compiler has been merged into the Kotlin repository. This helps ensure smoother migration of your projects to Kotlin 2.0.0, as the Compose compiler plugin and Kotlin versions with identical version numbers will always be compatible and will be shipped together (Kotlin 2.0.10 and the Compose compiler plugin 2.0.10, for example).
Along with the new compiler version, we released a new Compose compiler Gradle plugin that simplifies project setup and offers easy access to Compose compiler options.
For migration guides and other details, see the Compose compiler documentation.
Support for Kotlin 2.0.0
Compose Multiplatform 1.6.10 is fully compatible with Kotlin 2.0.0. Together with the new Compose compiler, this allows for easier and more flexible migration to the latest version of Kotlin.
Fleet features for Compose Multiplatform
Support for Compose development in Fleet 1.35 has improved across the board, including:
- Support for debugging Kotlin/Wasm code has been enhanced.
- Composable previews now update as you type.
- Accessors and navigation for multiplatform resources are updated for the 1.6.10 release, along with a few quality-of-life improvements for managing resources.
Other notable changes
To learn about the rest of the changes included in this release:
- See What’s new in Compose Multiplatform 1.6.10, where we further detail the improvements and features introduced in the 1.6.10 release.
- The Compose Multiplatform release notes on GitHub include an exhaustive list of merged pull requests for the 1.6.10 release.