Jetpack Compose Improves Performance
Written by Kay Ewbank   
Tuesday, 30 January 2024

Google has released version 1.6 of Jetpack Compose as part of its larger Compose January '24 Bill of Materials release. Google says this release largely focuses on performance improvements, courtesy of continued migration modifiers and improvement of the efficiency of major parts of the underlying API.

Android Jetpack is a suite of libraries for use in Android app development, and Compose is Android's modern, native UI toolkit that is Google's recommended way to build new Android apps for phone, tablets and foldables, and the addition of Compose for Wear adds the option of building Wear OS apps too.

The performance improvements, according to Google, have resulted in around a twenty percent improvement in scroll performance and a twelve percent improvement in startup time in Google's benchmarks, on top of the improvements from the August '23 release. The developers say that as with the earlier release, most apps will see these benefits just by upgrading to the latest version, with no other code changes needed.

The improvements have come from work on memory allocations and lazy initialization, to ensure the framework is only doing work when it has to.

The new version also includes an updated Compose compiler that has a new option that can be used to mark any class as stable, including your own modules, external library classes, and standard library classes, without having to modify these modules or wrap them in a stable wrapper class.

The code generated by the Compose compiler plugin has also been improved, providing more performance improvements, and to enable "intrinsic remember" by default. This means the compiler remembers to take into account information it already has about any parameters of a composable, so speeding up the calculation of determining if a remembered expression needs reevaluating.

The developers say they have also added support for an experimental mode called "strong skipping mode" that relaxes some of the rules about which changes can skip recomposition, moving the balance towards what developers expect. With strong skipping mode enabled, composables with unstable parameters can also skip recomposition if the same instances of objects are passed in to its parameters.

Jetpack Compose 1.6 is available now.

More Information

Jetpack Compose Website

Related Articles

Android Jetpack Wear OS Libraries Now Stable

Android Jetpack Confusion As V1 Approaches

Google Jetpack Compose UI Toolkit Now In Beta

Android Jetpack Compose Is Welcome, But What About The Churn?

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.


TypeScript 5.5 Adds ECMAScript Set Support

TypeScript 5.5 is now available as a release candidate. This version adds support for the proposed ECMAScript Set methods, as well as inferred type predicates and the ability to narrow expressions for [ ... ]

Get Started With Ollama's Python & Javascript Libraries

New libraries allow you to integrate new and existing apps with Ollama in just a few lines of code. Here we show you how to use ollama-python and ollama-javascript so that you can integrate Ollama's f [ ... ]

More News

C book



or email your comment to:

Last Updated ( Tuesday, 30 January 2024 )