A composable's lifecycle is three events, and none of them is onDestroy
Composables have a lifecycle, but it is nothing like a View's. Three events — enter, recompose, leave — and the identity rules that decide which one you get.
We use Google Analytics to see which pages help people. No ads, no profiles. Privacy Policy
Composables have a lifecycle, but it is nothing like a View's. Three events — enter, recompose, leave — and the identity rules that decide which one you get.
Compose does not re-run your whole screen when state changes. It re-runs the smallest restartable scopes that read the changed value. Once you can see those scopes, recomposition stops being mysterious.
@Composable is a compiler plugin that adds hidden parameters to your function. Once you know what it adds, the rules about calling context, skipping and recomposition stop being arbitrary.
In Views you fix UI by reaching in and mutating it. Compose removes that ability entirely. Understanding why the removal is the feature is what makes the rest of Compose make sense.
The Compose BOM aligns runtime artifacts. The Kotlin/Compose compiler is a separate alignment problem, and mixing the two up produces errors that look like your code is wrong when it isn't.
What a composable function actually is, the three layout blocks every screen is made of, and how to preview one without running the app.
XML made you invalidate the UI by hand. Compose recomposes only the nodes whose data changed — and that one difference reorders how you build a screen.
Before learning a new toolkit, work out what you already know. Four questions that decide where to start, applied to Jetpack Compose.
A verifier asked to confirm will confirm. Inverting the instruction to 'try to prove this wrong' found bugs that three rounds of review had passed, including one in the verifier itself.
A delete returned deleted:true while the item was still there. Four failures in one day shared a shape: the action reported on itself, and nothing read the state back.
Giving an agent a real browser removes the slowest loop in web debugging. The first thing that breaks is not your selectors — it is that a headless browser is refused at the edge.
A RED test fixture that passed because a comment explaining the omission contained the omitted string. The failure mode is generic: any test whose input mentions what it removes.