08
Effects and retained lifetimes
Trace composition effects from successful apply through coroutine ownership, then separate remembered, retained, saved, and process lifetimes.
- Side effects run after a successful applyTrace SideEffect and DisposableEffect from composition recording to apply-phase callbacks and remembered lifecycle.3 min →
- LaunchedEffect belongs to a keyed composition scopeTrace coroutine context, cancellation, rememberCoroutineScope ownership, and effect keys as lifetime identity.4 min →
- Remember, retain, and saved state are different lifetimesSeparate slot memory, in-memory transient retention, saved-state restoration, and process lifetime.5 min →
- Retention has its own store and observer lifecycleFollow RetainedValuesStore ownership, RetainObserver callbacks, RetainedEffect retirement, and DoNotRetain leak protection.4 min →