Please document the lessons learnt as a result of code review from T384362 and style items.
Description
Description
| Status | Subtype | Assigned | Task | ||
|---|---|---|---|---|---|
| Invalid | None | T381826 [EPIC] Migrate XMLs to use Jetpack Compose | |||
| Resolved | Dbrant | T386369 [Spike] [1 Days] Review implications and implementation of conversion of about screen to Jetpack Compose |
Event Timeline
Comment Actions
Annoyances
- Pretty much everything you know from the old XML Views architecture is hereby no longer applicable, and must be relearned. "Margins" are now "padding", "RecyclerView" is now "LazyColumn", "Spannable" strings are now "AnnotatedString" (and they're not compatible!), and on and on.
- Certain very specific things are weirdly missing, like a scrollbar that appears when a view is scrollable.
- A lot of things are still marked as "experimental" at the level of the framework, even though the documentation encourages us to use it. This signals a "move-fast-break-things" philosophy that we'll need to keep an eye on.
Good stuff
- The "Preview" system in Compose is actually quite useful. Everything from an individual component to an entire screen can have its own "Preview" function that serves as a miniature unit test and sanity check of how it will look. We should absolutely make sure to make Preview functions for everything.
- Compose basically forces the developer to use proper MVVM patterns, which is good for maintainability.
- If done right, this likely holds the promise of being more performant than the current system.
Questions
These are questions that will only be answered in time, as we delve deeper into Compose.
- How are transition animations done from one activity to another?
- Can we have an AnnotatedString with images, like we currently have with our Spanned strings?
- How is edge-to-edge behavior and/or insets handled?
...