Web Performance logo

Web Performance

Community
nimadorostkar
web-performance

Use when improving page load or runtime performance. Covers Core Web Vitals, bundle and asset optimization, rendering strategy, caching headers, and measuring on real hardware rather than a fast laptop. Trigger on "page loads slowly", "lcp is failing", "bundle is too big", "layout shift on load". Do not use for server load capacity — see the performance-testing skill; for slow queries behind the page, see the database-performance skill.

Overview

Publishernimadorostkar
RepositoryClaude-Skills-collection
Skill nameweb-performance
Stars
34
Forks
4
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by nimadorostkar on GitHub. Read the source before you install it.

Installation

Install the Web Performance AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/frontend/web-performance
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nimadorostkar/Claude-Skills-collection.git /tmp/Claude-Skills-collection
mkdir -p .claude/skills
cp -r /tmp/Claude-Skills-collection/skills/frontend/web-performance .claude/skills/web-performance
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Web Performance in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Web Performance on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Web Performance is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Web Performance

Purpose

Make pages fast on the devices people actually use. Performance work without measurement on representative hardware is guesswork, and it is usually spent on the wrong thing.

When to Use

  • Core Web Vitals failing in field data.
  • A page that feels slow, or a bundle that has quietly grown.
  • Before launching anything that matters commercially.
  • Diagnosing jank, layout shift, or slow interactions.

Capabilities

  • Core Web Vitals: LCP, INP, CLS — diagnosis and remediation.
  • Bundle analysis and code splitting.
  • Image, font, and asset optimization.
  • Caching and CDN header configuration.
  • Runtime profiling: long tasks, layout thrashing, memory growth.

Inputs

  • Field data (Chrome UX Report, RUM), not just a lab score.
  • The bundle, the network waterfall, and a CPU profile.
  • The device and network profile of the actual audience.

Outputs

  • A ranked list of fixes with expected impact.
  • Before/after measurements on throttled hardware.
  • Budgets in CI so the improvement holds.

Workflow

  1. Measure the field, not the lab — Lighthouse on a developer laptop tells you nothing about a mid-range Android on 4G. Start with real-user data and reproduce it with 4x CPU throttling and a Slow 4G profile.
  2. Find the LCP element — It is nearly always a hero image or a heading blocked by a font or a script. Preload it; do not lazy-load it.
  3. Fix INP by breaking up long tasks — Interaction latency comes from the main thread being busy. Find tasks over 50ms in the profile and yield, defer, or move them off-thread.
  4. Fix CLS by reserving space — Every image needs width and height or an aspect-ratio. Every ad slot, embed, and late-loading banner needs a reserved box.
  5. Cut the bundle — Analyze it. One date library, one icon set, or one un-tree-shaken utility library is usually a third of the payload.
  6. Set the cache headers — Immutable, fingerprinted assets get a one-year max-age. HTML gets no-cache and revalidates.
  7. Budget it in CI — Otherwise it regresses within two sprints.

Best Practices

  • Lazy-loading the LCP image makes LCP worse. loading="lazy" belongs below the fold, never above it.
  • font-display: swap prevents invisible text but causes a shift; size-adjust with a matched fallback metric prevents both.
  • Third-party scripts are the largest performance cost in most real applications, and the least examined. Audit them; load them with async, in a worker, or not at all.
  • A 200 KB JavaScript bundle costs far more than a 200 KB image: the image decodes off-thread, the JavaScript must be parsed and executed on the main thread.
  • Preconnect to critical third-party origins, but only two or three — each one costs a connection.
  • Do not optimize what the profile does not show. The bottleneck is rarely where intuition says it is.

Examples

Preloading the LCP image and the font that blocks it:

html
<link rel="preload" as="image"
      href="/hero-960.avif"
      imagesrcset="/hero-640.avif 640w, /hero-960.avif 960w, /hero-1440.avif 1440w"
      imagesizes="(max-width: 768px) 100vw, 960px"
      fetchpriority="high" />

<link rel="preload" as="font" type="font/woff2"
      href="/fonts/inter-var.woff2" crossorigin />

<img src="/hero-960.avif" width="1440" height="810"
     alt="" fetchpriority="high" />   <!-- dimensions reserve space: no CLS -->

Breaking a long task to fix INP:

javascript
// Before: 400ms of blocking work on click. INP is terrible.
button.addEventListener("click", () => {
  const results = items.map(expensiveTransform);   // blocks the main thread
  render(results);
});

// After: yield to the browser between chunks so input stays responsive.
async function processInChunks(items, chunkSize = 50) {
  const out = [];
  for (let i = 0; i < items.length; i += chunkSize) {
    out.push(...items.slice(i, i + chunkSize).map(expensiveTransform));
    await scheduler.yield();   // hand control back; the browser can paint and respond
  }
  return out;
}

Notes

  • INP replaced FID as a Core Web Vital in March 2024. It measures every interaction, not just the first, and it is a far harder bar — most sites that passed FID comfortably do not pass INP.
  • Compression matters more than minification: Brotli at level 11 on a 300 KB bundle typically beats aggressive minification by a wider margin than the minifier does.
  • content-visibility: auto skips rendering work for off-screen content and is close to free on long pages. It is one of the highest-value single-property changes available.

Frequently asked questions

What does the Web Performance AI skill do?

Use when improving page load or runtime performance. Covers Core Web Vitals, bundle and asset optimization, rendering strategy, caching headers, and measuring on real hardware rather than a fast laptop. Trigger on "page loads slowly", "lcp is failing", "bundle is too big", "layout shift on load". Do not use for server load capacity — see the performance-testing skill; for slow queries behind the page, see the database-performance skill.

Why use Web Performance on TypingMind?

Because you install it once and use it with any model. Web Performance is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Web Performance in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/frontend/web-performance. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Web Performance?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Web Performance?

As many as you like. As long as a model supports skills, you can use Web Performance with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Web Performance AI skill free?

Yes. It is published on GitHub by nimadorostkar under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇