jetc.dev Newsletter Issue #139
This week, we look at the new stable Compose 1.3.0… and what comes afterwards!
We also have a long list of Android Dev Summit videos, a look at applying a state machine to Compose state, and a new Google tool to convert Figma diagram components into composables.
Ooooo… What Did We Get?
Reviewing the release notes for the latest Jetpack Compose update!
First, we now have a bill of materials (BOM)
for applying a consistent set of Compose artifacts. The documentation
shows how to use it.
2022.10.00 edition of the BOM points to Compose 1.3.0, the new stable
minor version. Google’s Jolanda Verhoef also has a linked set of tweets
describing how to use the BOM.
But, stuff never stays stable for long, as we also now have
toMap(), with implementations that avoid data copies
We also got a
beta01 for Wear Compose
1.1.0. In addition to bug fixes,
we can now specify font details (e.g., family, weight) to
Android Dev Summit 2022
Google held the first phase of the Android Dev Summit 2022 in Mountain View. The event consisted of a dizzying array of short presentations (the longest was about 25 minutes, and most were under 10 minutes). Ones expressly on Compose include:
There were other presentations related to Compose as well, such as “Introducing Relay” and “State holders and state production in the UI layer”.
One Off the Stack, One Off the Slack
You’ve got questions. That’s understandable!
The good news is that
FocusRequester() and the
make it easy to change the focus. However… not everything is focusable by
default, necessitating the use of the
focusable() modifier. See this in action
in this week’s highlighted Stack Overflow question.
Animating the background of a UI element to draw attention to it is reasonably
common. However, this requires an animation with limited repetition: not just once
and not forever. You have a few options for this, as we see in this week’s highlighted
#compose Slack thread.
Posts, videos, and other new information related to Jetpack Compose!
Google’s Jolanda Verhoef provided us with the official announcement of the Compose 1.3.0 stable release, the Compose BOM, and more! The post includes links to the Lyft marketing piece and the Zepeto marketing piece, describing their experiences with Compose.
Google’s Rebecca Franks and Simona Stojanovic delivered one of the Android Dev Summit 2022.1 presentations, “Custom layouts and graphics in Compose”. Rebecca also wrote up a series of tweets describing how JetLagged — the sleep tracking app profiled in that presentation — was set up.
Marco Cattaneo reviews FlowRedux, a Kotlin/Multiplatform library that offers a DSL for describing state machines. Marco applies this to the content/loading/error state triple often used in resource-bound UI, specifically for loading the roster of GitHub repositories for a particular GitHub user.
Other Interesting Links
- Gestures in Jetpack Compose: Getting Started
- Medium: Compose edge-to-edge animation
- Medium: Animated Switch Button using Jetpack Compose
- Medium: Jetpack Compose Basics — Part 2
- Android Compose – An Introduction to Declarative Android UI Development
- Medium: Android Jetpack Compose UI Part-2
- How to create realistic UI with Jetpack Compose
100% pure code!
Google has released Relay. Relay is a pair of plugins, one for Figma, one for Android Studio. The plugins let you package up and export a component from a Figma design, then import that into Android Studio and have it code-generate Compose UI code for you.
Other Interesting Links
- 2022-11-15: Compose 1.3.1 and 1.4.0-alpha02! Android Developer Summit! Android Worldwide! Relay! Permissions! Showcase views! And... a not-quite-complete autocomplete?!?
- 2022-11-08: Tables! Relay! Shaders! Intrinsics! Integration tests! Mocking composables! And... this newsletter is becoming buttoned down?!?
- 2022-11-01: Compose 1.3.0 stable! Android Dev Summit videos! State machines! Relay! And... someone set us up the BOM?!?