chrisbanes/skills

compose-performance

Use when investigating Jetpack Compose recomposition cost, compiler stability reports, skippability, unstable parameters, frame-rate State reads, cross-phase snapshot back-writing, or @ReadOnlyComposable contracts.

Zobacz źródło
Oryginalny dokument Skill

Treść z repozytorium z zachowaniem nagłówków, przykładów, kodu, tabel, linków i obrazów.

Compose performance

Core principle

Measure one user-visible transition, identify the runtime axis that causes the work, then apply the smallest correction at the phase or boundary where that axis begins.

Procedure

  1. Reproduce one concrete transition and capture the observable evidence:

recomposition counts, compiler reports, profiler data, or a clear trace.

  1. Classify the primary axis: parameter stability and skipping, State read

phase, or snapshot state written back into an earlier phase.

  1. Check for a false lead: a real data change, a correctness defect, or an

unchanged lazy item that is expected to recompose.

  1. Read the corresponding focused reference before proposing a change.
  2. For review work, pair every finding with the smallest evidence-supported

repair. For a false stability promise, explicitly say to replace mutable non-snapshot properties with immutable data or snapshot-observable state, verify that contract, and only then decide whether an annotation remains needed. For a phase problem, name the layout or draw consumer where the changing read or calculation should move. A cross-phase write proves invalidation or an extra pass; do not claim oscillation or an infinite loop unless evidence shows values repeatedly changing. Do not stop at diagnosis.

  1. Change one axis at a time and re-measure the same transition.
  2. Finish when the evidence improves at the observed boundary without hiding

state changes, caching stale values, or moving work to a less correct owner.

Topic router

SignalRead
Cause is unknown, or several axes may interactDiagnosis
classes.txt, composables.txt, strong skipping, unstable parameters, or collection stabilityStability
Scroll, animation, gesture, layout, or draw State read at frame rate; measured state fed back into compositionDeferred reads
A composable only reads composition locals or accessor-style valuesComposition contracts
State ownership or effect lifecycle is the root causeCompose state and effects
z tego samego repozytorium

Więcej Skills

Wszystkie Skills
chrisbanes
Społeczność

compose-ui-testing-patterns

Use when writing or reviewing Jetpack Compose UI tests, screenshot tests, previews, semantics assertions, fake image loading, keyboard input, focus assertions, interaction state (hover/pressed/focused), or tests for plain state-driven UI composables.

instalacje
4
GitHub Stars
1 tys.
Aktualizacja
21 wrz
chrisbanes
Społeczność

compose-animations

Use when writing or reviewing Jetpack Compose motion: visibility enter/exit, animating one property toward a target, color or size transitions, multiple properties from one state, switching composable content, or choosing between AnimatedVisibility, animateAsState, rememberTransition, AnimatedContent, and Crossfade.

instalacje
3
GitHub Stars
1 tys.
Aktualizacja
21 wrz
chrisbanes
Społeczność

compose-component-design

Use when designing or reviewing reusable Jetpack Compose component APIs with modifier parameters, root layout placement, caller-provided variable content, primitive content parameters, optional content, or boolean shape flags.

instalacje
3
GitHub Stars
1 tys.
Aktualizacja
21 wrz
chrisbanes
Społeczność

compose-focus-navigation

Use when writing or reviewing Jetpack Compose UI for TV, keyboard, desktop, accessibility focus, D-pad navigation, FocusRequester, focusProperties, key events, or initial focus behavior.

instalacje
3
GitHub Stars
1 tys.
Aktualizacja
21 wrz