jetc.dev Newsletter Issue #53
In all likelihood, tomorrow will see the dawn of the
beta01 release of Compose
and Compose UI! So, in this issue, we link to the livestream and take a look at
what Google is likely to do in the next few months.
Along with that, we have some chips (without fish), look at the swipe-to-reveal pattern and role semantics for accessibility, and peek at a bunch of Compose for Desktop projects on GitHub.
One Off the Stack, One Off the Slack
You’ve got questions. That’s understandable!
Chips — words or phrases surrounded by a square or rounded rectangle — are a
popular UI for keywords. You can implement them fairly easily in Compose UI by
Text() with a
Surface() that sets its
color, as we see
in this week’s highlighted Stack Overflow thread.
As we continue down the track towards a stable release, developers are getting
increasingly worried about perceived performance issues with Compose UI. Google’s
Adam Powell explained where Google’s focus will be in the coming months and put out a call
for your help, in this week’s highlighted Kotlinlang
#compose Slack thread.
Posts, videos, and other new information related to Jetpack Compose!
Denis Rudenko is exploring the swipe-to-reveal UI pattern, where a short horizontal
swipe gesture on a list row uncovers actions to take against that item, such as edit
or delete. Compose UI does not offer this “out of the box”, so Denis created a
DraggableCard() to implement this pattern.
Thomas Künneth follows up last week’s post
and looks more at implementing action bar patterns in Compose UI. This time, he
focuses on actions and drop-down menus, translating their menu resource into
Compose UI equivalents for use with a
Scaffold() and its
Rasul Aghakishiyev returns with a continuation of his previous work
ShapeableView(). This time, he adds rounded corners as an option,
along with the previous cut-corners implementation.
Bryan Herbst continues his coverage of Compose UI’s accessibility options, this
time looking at the
semantics() modifier and its
role parameter. This lets you
describe the general nature of a composable based upon classic UI roles (e.g., button),
to help TalkBack and similar accessibility services describe your UI to visually
Cleverlance continues their analysis of Compose and Compose UI, following up on their original post, showing some of the pros and cons of using Compose in production apps.
100% pure code!
GitHub user theapache64 opened up a pair of repositories recently. This one is a Compose for Desktop app for identifying the name for a user-selected color. This includes integration with the desktop clipboard and even generates a Compose UI snippet for defining that color in your app. theapache64 also released stackzy, a tool written in Compose for Desktop for examining apps on a connected device and determining what major libraries they use.
…And One More Thing
It is all but assured that tomorrow, we will get the
beta01 release of
Last week, I argued that this beta release was rushed, and I stand by that assessment. However, “time and tide wait for no man”, so Compose will now take another major step towards its first stable release.
Here is what I expect will transpire:
beta01will be released tomorrow.
Google will continue with the every-other-week release cadence, outside of occasional hiccups, at least through the beta releases. I would not be shocked if things slow down when we get to
rcreleases, though. Most Jetpack libraries are slower about updating
Google likes to claim that a beta release offers a stable API surface. In reality, API changes are not uncommon in betas, though usually they are more limited than the API changes that we see in alphas. Plus, APIs are more fluid in the run-up to a stable 1.0.0 release than in later releases. So, while major refactorings are probably done for now, I expect that the API will still change somewhat during the Compose beta period.
Google’s primary focus will be on performance and stability, and API changes will be tied into those concerns. In other words, we are unlikely to get new composables or modifiers, but we might get some changes to parameter lists, as performance and stability fixes trigger the need for new parameters, changes from booleans to enums, and the like.
We will get six beta releases or more. That stems mostly from the sheer size of Compose and Compose UI, as there is a lot of performance and stability ground to cover. That will take time, and if they stick with the bi-weekly release cadence, that means a lot of beta releases. However, with fewer changes to the API, taking on beta upgrades hopefully will be fairly easy.
To me, the biggest mystery in terms of timeframe is how they will handle the RC releases, in terms of cadence and number. But, between beta and RC releases, I would not be surprised if we are still 4-5 months away from a stable 1.0.0 release. That is well within Google’s stated timeline, which called for a stable 1.0.0 release by the end of 2021. People looking to provide educational resources related to Compose and Compose UI (👋) can use the time!
Regardless of that timeframe, though, the next phase of Jetpack Compose’s evolution begins tomorrow. It will be interesting to see how it turns out!
- 2023-11-21: Compose/Material3/Wear Compose updates! remember()! Adaptive layouts! Compose Multiplatform in 2024! @email@example.com on BasicTextField2()! Compose Multiplatform charts! And... is TV Compose in trouble?!?
- 2023-11-14: Compose Compiler! BasicTextField2()! @firstname.lastname@example.org and animations! Optimization! @email@example.com, JetBrains, and Fleet! JetBrains and plotting! And... we collapse?!?
- 2023-11-07: Compose Multiplatform! Chips in fields! Diffing! Custom fonts in Glance app widgets! Heatmaps! PIN input! And @firstname.lastname@example.org is in a bit of a haze?!?