using-strong-skipping-correctly

Installation
SKILL.md

Using Strong Skipping Correctly — make every restartable composable skippable, intentionally

Strong Skipping Mode is the Compose compiler behavior that became the default with the Kotlin Compose compiler plugin shipped in Kotlin 2.0.20. It changes two things at once: every restartable composable becomes skippable regardless of param stability (unstable params are compared with ===, stable params with equals), and every capturing lambda literal written inside a @Composable function is automatically wrapped in remember(captures) { ... }. Both behaviors are on by default; neither requires opt-in flags on Kotlin 2.0.20+. Lambdas with no captures are already compiler-emitted singletons and are NOT wrapped — only capturing lambdas need (and get) the auto-remember treatment.

That sounds like "stability no longer matters", and for a lot of UI code it almost is. But the change leaves three sharp edges: stable types still need correct equals semantics so the === fallback does not invalidate every recompose, lambdas in non-@Composable scopes (LazyListScope.items { }, Modifier.pointerInput { }, plain object expressions) are not auto-memoized, and a few intentional cases need explicit opt-out via @DontMemoize or @NonSkippableComposable. This skill walks the verification, audit, and escape-hatch decisions for working in a strong-skipping world.

When to use this skill

  • The developer asks "do I still need @Stable?" or "does this composable skip now?".
  • A composable still recomposes on every parent tick even though the developer "thought strong skipping fixed that".
  • A lambda allocation question comes up — "is this onClick = { vm.add(it) } allocating per recompose?".
  • Migrating a project from Kotlin 1.9.x / Compose Compiler 1.5.x to Kotlin 2.0.20+ and reconciling reports that now show restartable skippable everywhere.
  • The developer encounters @DontMemoize or @NonSkippableComposable in code or compiler output and asks what they do.
  • The user mentions "strong skipping", "auto-remember", "@DontMemoize", "@NonSkippableComposable", or "skippable everywhere".

When NOT to use this skill

Related skills

More from skydoves/compose-performance-skills

Installs
8
GitHub Stars
377
First Seen
Apr 29, 2026