agentleFS
UwayxtUwayxt/agent-skills/.agents/skills/perceived-performance-loading/SKILL.md

perceived-performance-loading

Skill4 starsChanged 2 months agoMITView on GitHub

Define loading strategies that make the product feel fast regardless of actual load time. Use when skeleton loaders, lazy loading, progressive rendering, perceived performance, or mobile loading speed.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Critical (above-the-fold): must be visible within the first meaningful paint.

    line 10
  2. Distinctive:

    Use a shimmer animation (left-to-right highlight sweep) for active loading

    line 17
  3. Very specific:

    Use native loading="lazy" for below-fold images

    line 29
  4. Distinctive:

    Use blur-up placeholder (low-res image → full-res) for hero images

    line 31
  5. Distinctive:

    All content classified (critical / important / deferred)

    line 44
  6. Distinctive:

    No offline state — blank screen or broken layout when connection drops

    line 58

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “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

Perceived performance is a design problem, not only an engineering problem. A blank screen for 2 seconds feels slower than a skeleton loader for 3 seconds. Design the loading experience first.

1. Classify content by load priority

Three tiers:

  • Critical (above-the-fold): must be visible within the first meaningful paint. No lazy loading.
  • Important (below-the-fold): load after critical content, can use lazy loading with a low threshold.
  • Deferred (off-screen, secondary): load on demand (scroll, tab change, user action).

2. Design skeleton screens

For every content block that takes >300ms to load, design a skeleton version:

  • Match the exact layout and dimensions of the real content (not generic gray bars)
  • Use a shimmer animation (left-to-right highlight sweep) for active loading
  • Transition from skeleton → real content with a subtle fade (no jarring replacement) Reference motion tokens from micro-interaction-motion-design for animation timing.

3. Define progressive rendering

For data-heavy views (tables, lists, feeds):

  • Render the first N items immediately
  • Load remaining items as user scrolls (virtual scrolling for very long lists)
  • Show a count indicator ("Showing 20 of 342 results")

4. Optimize image loading

Specify:

  • Use native loading="lazy" for below-fold images
  • Define image size hints (width and height attributes) to prevent layout shift
  • Use blur-up placeholder (low-res image → full-res) for hero images
  • Specify acceptable image formats (WebP with fallback, AVIF where supported)

5. Handle connection variability (mobile-critical)

Define behavior for:

  • Slow 3G: show skeleton, load text first, images last
  • Offline: show cached content with a clear "You are offline" indicator, not a blank screen
  • Connection restored: auto-refresh without losing scroll position

6. Set loading time budgets

First Contentful Paint target, Largest Contentful Paint target, Total Blocking Time target. These are design constraints, not just engineering metrics.

Completion Criteria

  • All content classified (critical / important / deferred)
  • Skeleton screens designed for all content blocks >300ms
  • Progressive rendering defined for all lists/tables >20 items
  • Image loading strategy specified
  • Offline state handled
  • Performance budgets set

Output

Loading strategy document + skeleton screen specifications + performance budget targets.

Anti-patterns

  • Generic spinner as the only loading indicator (tells the user nothing about structure)
  • Skeleton that does not match real content dimensions (causes layout shift on load)
  • Lazy loading images that are above the fold (delays critical content)
  • No offline state — blank screen or broken layout when connection drops
  • Loading all data upfront for large lists (defeats the purpose of pagination/virtual scroll)

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.