Compose Correctness

Use when Jetpack Compose UI code is written or reviewed and the risk is wrong behaviour or needless recomposition: where state lives and how it survives rotation (hoisting, remember versus rememberSaveable, mutable lists as state), choosing LaunchedEffect, DisposableEffect, SideEffect, rememberUpdatedState, derivedStateOf or snapshotFlow, collecting flows with collectAsStateWithLifecycle, reading fast-changing state late with lambda modifiers, backwards writes, composable skipping and stability (strong skipping, unstable collections, @Stable), and lazy list keys and content types.

techmefr Updated

File contents

techmefr/mentis commit f86f403d13

Frequently asked questions

npx get-skill add techmefr/compose-correctness