agentleFS
evolplusevolplus/talos/skills/flutter-performance/SKILL.md

flutter-performance

Skill9 starsChanged 6 months agoApache-2.0View on GitHub

Flutter performance guidance for FE Dev. Use for slow widgets, rebuild churn, jank, large lists, image-heavy UI, animations, startup time, memory pressure, isolates, expensive layout/paint, or performance review of Flutter code.

5 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use flutter-architecture, flutter-security and 1 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • MADTeacherSkill

    flutter-architecture

    Design, refactor, review, or implement Flutter app architecture using MVVM, layered UI/Data/optional Domain boundaries, feature-first or layer-first project structure, repositories, services, dependency injection, Result and Command patterns, offline-first or optimistic UI flows. Use when asked to add a Flutter feature, audit layer dependencies, fix cross-feature imports, migrate to feature-first, choose architecture for a Flutter project, or create scalable maintainable Flutter code organization.

    Also in 4 projects that use this

  • dhruvanbhalaraSkill

    flutter-security

    Use when securing local storage with flutter_secure_storage, enforcing AES-256-GCM encryption, or adding biometric authentication gates.

    Also in 3 projects that use this

  • dhruvanbhalaraSkill

    flutter-testing

    Use when defining automated testing strategies, organizing test pyramids, or establishing test naming conventions across Flutter apps.

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

22 rules. 0 are common, 13 are distinctive, and 9 are very specific to this project.

  • 0

    Common

    Most of the 5 edited versions we read keep these.

  • 13

    Distinctive

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use this when a Flutter task touches performance-sensitive UI: large lists, image-heavy layouts, charts, animations, startup, memory …

    line 14
  2. Very specific:

    prefer const constructors and immutable inputs.

    line 27
  3. Distinctive:

    keep state close to the widget subtree that changes.

    line 28
  4. Very specific:

    use selectors/consumers/builders from the project's state library to narrow rebuild scope.

    line 29
  5. Very specific:

    avoid allocating expensive derived collections in build().

    line 30
  6. Very specific:

    use ListView.builder, SliverList, grids, or project virtualized components for dynamic collections.

    line 32
  7. Very specific:

    avoid shrinkWrap and nested scrollables on large lists unless the layout truly requires them.

    line 34
  8. Very specific:

    keep empty/loading/refresh states explicit.

    line 35
  9. Distinctive:

    use caching through the project image pipeline.

    line 38
  10. Distinctive:

    avoid decoding oversized images in hot list cells.

    line 39
  11. Distinctive:

    use placeholders and error widgets that match the visual spec.

    line 40
  12. Distinctive:

    prefer implicit animations or existing animation primitives for simple transitions.

    line 42
  13. Distinctive:

    keep animation controllers scoped and disposed.

    line 43
  14. Distinctive:

    avoid work in listeners that runs every frame unless it is trivial.

    line 44
  15. Distinctive:

    use existing repository/background mechanisms first.

    line 47
  16. Very specific:

    consider isolates/compute for CPU-heavy transforms only when serialization cost is worth it.

    line 48
  17. Distinctive:

    do not parse large payloads synchronously in widget code.

    line 49
  18. Distinctive:

    run the narrowest repeatable check: profile build smoke, DevTools frame capture, list scroll test, animation test, or memory check.

    line 51
  19. Distinctive:

    Do not optimize by weakening accessibility, selector stability, state coverage, or manifest completeness.

    line 56
  20. Very specific:

    Do not add a new image/list/state/performance library without dependency approval.

    line 57
  21. Distinctive:

    Do not solve rebuild churn by making shared mutable global state.

    line 58
  22. Distinctive:

    Do not tune only in debug mode when the issue is production performance.

    line 59

“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Flutter Performance

When to use

Use this when a Flutter task touches performance-sensitive UI: large lists, image-heavy layouts, charts, animations, startup, memory pressure, expensive rebuilds, platform-channel traffic, or jank. Load it alongside flutter-implementation.

Inputs and outputs

  • Inputs: affected widgets/pages, existing profiling or QA evidence, device/emulator target, design manifest, data size assumptions, current state/image/list/animation libraries.
  • Outputs: targeted performance changes with preserved behavior, measurable before/after evidence when feasible, and tests/checks that prove no manifest or accessibility regression.

Procedure

  1. Define the performance surface:
    • name the slow path, expected data volume, device class, platform, and success criterion;
    • inspect existing Flutter DevTools/profile evidence before changing code when available.
  2. Control rebuilds:
    • prefer const constructors and immutable inputs;
    • keep state close to the widget subtree that changes;
    • use selectors/consumers/builders from the project's state library to narrow rebuild scope;
    • avoid allocating expensive derived collections in build().
  3. Tune lists and scrolling:
    • use ListView.builder, SliverList, grids, or project virtualized components for dynamic collections;
    • provide stable keys where item identity matters;
    • avoid shrinkWrap and nested scrollables on large lists unless the layout truly requires them;
    • keep empty/loading/refresh states explicit.
  4. Handle image and asset cost:
    • request appropriately sized images;
    • use caching through the project image pipeline;
    • avoid decoding oversized images in hot list cells;
    • use placeholders and error widgets that match the visual spec.
  5. Keep animation smooth:
    • prefer implicit animations or existing animation primitives for simple transitions;
    • keep animation controllers scoped and disposed;
    • avoid work in listeners that runs every frame unless it is trivial;
    • respect reduced-motion behavior when the project supports it.
  6. Move heavy work off the UI isolate:
    • use existing repository/background mechanisms first;
    • consider isolates/compute for CPU-heavy transforms only when serialization cost is worth it;
    • do not parse large payloads synchronously in widget code.
  7. Verify:
    • run the narrowest repeatable check: profile build smoke, DevTools frame capture, list scroll test, animation test, or memory check;
    • record unmeasured performance assumptions in task notes instead of presenting them as proof.

Hard rules

  • Do not optimize by weakening accessibility, selector stability, state coverage, or manifest completeness.
  • Do not add a new image/list/state/performance library without dependency approval.
  • Do not solve rebuild churn by making shared mutable global state.
  • Do not tune only in debug mode when the issue is production performance.

References

  • ../flutter-implementation/SKILL.md - baseline Flutter implementation discipline.
  • ../third-party-dependency-evaluation/SKILL.md - dependency approval for new performance libraries.
  • ../ui-test-execution/SKILL.md - UI regression checks after performance changes.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.