Agent skill

React Performance Optimizer

by curiositech in curiositech/some_claude_skills

Optimize React apps for 60fps performance. An agent skill from curiositech/some_claude_skills.

MITAuto-check passedFrontend & Design

Install React Performance Optimizer

skills CLI
$ npx skills add curiositech/some_claude_skills --skill react-performance-optimizer -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install curiositech/some_claude_skills react-performance-optimizer --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/curiositech/some_claude_skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/react-performance-optimizer .claude/skills/react-performance-optimizer && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
react-performance-optimizer
GitHub stars
243
Token cost
~2.8k tokens
SKILL.md length
420 words
Files
7 (incl. scripts, references)
Skills in repo
108
Repo updated
First seen
Licence
MIT

At a glance

Optimize React apps for 60fps performance. An agent skill from curiositech/some_claude_skills.

  • Works in 3 steps: Computation takes >5ms (use Profiler… → Result used in dependency array → Prevents child re-renders
  • Tasks that involve Web performance
  • SKILL.md covers When to Use, Quick Decision Tree, Technology Selection and Common Anti-Patterns, plus 5 more sections
  • Runs Shell and TypeScript scripts from its folder

What it does

React Performance Optimizer is an agent skill from curiositech/some_claude_skills. Optimize React apps for 60fps performance. Implements memoization, virtualization, code splitting, bundle optimization. Use for slow renders, large lists, bundle bloat. Activate on "React performance", "slow render", "useMemo", "bundle size", "virtualization". NOT for backend optimization, non-React frameworks, or premature optimization.

Its SKILL.md is about 2.8k tokens, which your agent loads only when the skill is triggered. The skill folder holds 9 other files, including scripts and reference files (for example `.claude-plugin/plugin.json`, `references/bundle-optimization.md` and `references/memory-leaks.md`).

It sits in Frontend & Design, covering Web performance. It works with React. The repository describes itself as: Claude skills that make my life easier. The licence is MIT.

When your agent uses it

  • Tasks that involve Web performance

Example prompts

  • “React performance”
  • “slow render”
  • “useMemo”
  • “/react-performance-optimizer”

Requirements

  • Node.js
  • A Bash shell
  • Pre-approved tools (allowed-tools): Read, Write, Edit, Bash(npm:*)

Workflow steps

3 steps, taken from the first numbered list in SKILL.md.

  1. Computation takes >5ms (use Profiler to measure)
  2. Result used in dependency array
  3. Prevents child re-renders

What it can do on your machine

Read from SKILL.md and the folder at commit 6713fc7. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Edit
    • Bash(npm:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 2 files in scripts/ (Shell and TypeScript), which the agent can run.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

React Performance Optimizer loads about 2.8k tokens when it runs, and up to ~13k if it reads all its reference files. Until then it costs about 92 tokens; SKILL.md has 420 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~92
When it runs · the whole SKILL.md, loaded when a task matches
~2.8k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~13k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from curiositech/some_claude_skills at commit 6713fc7, republished under its MIT licence (© curiositech). 420 words, ~2,814 tokens.

Download SKILL.mdSave it as .claude/skills/react-performance-optimizer/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.
name
react-performance-optimizer
description
Optimize React apps for 60fps performance. Implements memoization, virtualization, code splitting, bundle optimization. Use for slow renders, large lists, bundle bloat. Activate on "React performance", "slow render", "useMemo", "bundle size", "virtualization". NOT for backend optimization, non-React frameworks, or premature optimization.
allowed-tools
Read, Write, Edit, Bash(npm:*)
metadata.tags
react, performance, optimizer, react-performance, slow-render

React Performance Optimizer

Expert in diagnosing and fixing React performance issues to achieve buttery-smooth 60fps experiences.

When to Use

✅ Use for:

  • Slow component re-renders
  • Large lists (>100 items) causing lag
  • Bundle size >500KB (gzipped)
  • Time to Interactive >3 seconds
  • Janky scrolling or animations
  • Memory leaks from unmounted components

❌ NOT for:

  • Apps with <10 components (premature optimization)
  • Backend API slowness (fix the API)
  • Network latency (use caching/CDN)
  • Non-React frameworks (use framework-specific tools)

Quick Decision Tree

Is your React app slow?
├── Profiler shows &gt;16ms renders? → Use memoization
├── Lists with &gt;100 items? → Use virtualization
├── Bundle size &gt;500KB? → Code splitting
├── Lighthouse score &lt;70? → Multiple optimizations
└── Feels fast enough? → Don't optimize yet

Technology Selection

Performance Tools (2024)
ToolPurposeWhen to Use
React DevTools ProfilerFind slow componentsAlways start here
LighthouseOverall performance scoreBefore/after comparison
webpack-bundle-analyzerIdentify large dependenciesBundle >500KB
why-did-you-renderUnnecessary re-rendersDebug re-render storms
React Compiler (2024+)Automatic memoizationReact 19+

Timeline:

  • 2018: React.memo, useMemo, useCallback introduced
  • 2020: Concurrent Mode (now Concurrent Rendering)
  • 2022: Automatic batching in React 18
  • 2024: React Compiler (automatic optimization)
  • 2025+: React Compiler expected to replace manual memoization

Common Anti-Patterns

Anti-Pattern 1: Premature Memoization

Novice thinking: "Wrap everything in useMemo for speed"

Problem: Adds complexity and overhead for negligible gains.

Wrong approach:

typescript
// ❌ Over-optimization
function UserCard({ user }) {
  const fullName = useMemo(() => `${user.first} ${user.last}`, [user]);
  const age = useMemo(() => new Date().getFullYear() - user.birthYear, [user]);

  return <div>{fullName}, {age}</div>;
}

Why wrong: String concatenation is faster than useMemo overhead.

Correct approach:

typescript
// ✅ Simple is fast
function UserCard({ user }) {
  const fullName = `${user.first} ${user.last}`;
  const age = new Date().getFullYear() - user.birthYear;

  return <div>{fullName}, {age}</div>;
}

Rule of thumb: Only memoize if:

  1. Computation takes >5ms (use Profiler to measure)
  2. Result used in dependency array
  3. Prevents child re-renders

Anti-Pattern 2: Not Memoizing Callbacks

Problem: New function instance on every render breaks React.memo.

Wrong approach:

typescript
// ❌ Child re-renders on every parent render
function Parent() {
  const [count, setCount] = useState(0);

  return (
    <Child onUpdate={() => setCount(count + 1)} />
  );
}

const Child = React.memo(({ onUpdate }) => {
  return <button onClick={onUpdate}>Update</button>;
});

Why wrong: Arrow function creates new reference → React.memo useless.

Correct approach:

typescript
// ✅ Stable callback reference
function Parent() {
  const [count, setCount] = useState(0);

  const handleUpdate = useCallback(() => {
    setCount(c => c + 1);  // Updater function avoids dependency
  }, []);

  return <Child onUpdate={handleUpdate} />;
}

const Child = React.memo(({ onUpdate }) => {
  return <button onClick={onUpdate}>Update</button>;
});

Anti-Pattern 3: Rendering Large Lists Without Virtualization

Problem: Rendering 1000+ DOM nodes causes lag.

Symptom: Scrolling feels janky, initial render slow.

Wrong approach:

typescript
// ❌ Renders all 10,000 items
function UserList({ users }) {
  return (
    <div>
      {users.map(user => (
        <UserCard key={user.id} user={user} />
      ))}
    </div>
  );
}

Correct approach:

typescript
// ✅ Only renders visible items
import { FixedSizeList } from 'react-window';

function UserList({ users }) {
  return (
    <FixedSizeList
      height={600}
      itemCount={users.length}
      itemSize={50}
      width="100%"
    >
      {({ index, style }) => (
        <div style={style}>
          <UserCard user={users[index]} />
        </div>
      )}
    </FixedSizeList>
  );
}

Impact: 10,000 items: 5 seconds → 50ms render time.


Show full SKILL.md (152 more words)Show less
Anti-Pattern 4: No Code Splitting

Problem: 2MB bundle downloaded upfront, slow initial load.

Wrong approach:

typescript
// ❌ Everything in main bundle
import AdminPanel from './AdminPanel';  // 500KB
import Dashboard from './Dashboard';
import Settings from './Settings';

function App() {
  return (
    <Routes>
      <Route path="/admin" element={<AdminPanel />} />
      <Route path="/dashboard" element={<Dashboard />} />
      <Route path="/settings" element={<Settings />} />
    </Routes>
  );
}

Correct approach:

typescript
// ✅ Lazy load routes
import { lazy, Suspense } from 'react';

const AdminPanel = lazy(() => import('./AdminPanel'));
const Dashboard = lazy(() => import('./Dashboard'));
const Settings = lazy(() => import('./Settings'));

function App() {
  return (
    <Suspense fallback={<Loading />}>
      <Routes>
        <Route path="/admin" element={<AdminPanel />} />
        <Route path="/dashboard" element={<Dashboard />} />
        <Route path="/settings" element={<Settings />} />
      </Routes>
    </Suspense>
  );
}

Impact: Initial bundle: 2MB → 300KB.


Anti-Pattern 5: Expensive Operations in Render

Problem: Heavy computation on every render.

Wrong approach:

typescript
// ❌ Sorts on every render (even when data unchanged)
function ProductList({ products }) {
  const sorted = products.sort((a, b) => b.price - a.price);

  return <div>{sorted.map(p => <Product product={p} />)}</div>;
}

Correct approach:

typescript
// ✅ Memoize expensive operation
function ProductList({ products }) {
  const sorted = useMemo(
    () => [...products].sort((a, b) => b.price - a.price),
    [products]
  );

  return <div>{sorted.map(p => <Product product={p} />)}</div>;
}

Implementation Patterns

Pattern 1: React.memo for Pure Components
typescript
// Prevent re-render when props unchanged
const ExpensiveComponent = React.memo(({ data }) => {
  // Complex rendering logic
  return <div>{/* ... */}</div>;
});

// With custom comparison
const UserCard = React.memo(
  ({ user }) => <div>{user.name}</div>,
  (prevProps, nextProps) => {
    // Return true if props equal (skip re-render)
    return prevProps.user.id === nextProps.user.id;
  }
);
Pattern 2: useMemo for Expensive Calculations
typescript
function DataTable({ rows, columns }) {
  const sortedAndFiltered = useMemo(() => {
    console.log('Recomputing...');  // Only logs when rows/columns change

    return rows
      .filter(row => row.visible)
      .sort((a, b) => a.timestamp - b.timestamp);
  }, [rows, columns]);

  return <Table data={sortedAndFiltered} />;
}
Pattern 3: useCallback for Stable References
typescript
function SearchBox({ onSearch }) {
  const [query, setQuery] = useState('');

  // Stable reference, doesn't break child memoization
  const handleSubmit = useCallback(() => {
    onSearch(query);
  }, [query, onSearch]);

  return (
    <form onSubmit={handleSubmit}>
      <input value={query} onChange={e => setQuery(e.target.value)} />
    </form>
  );
}
Pattern 4: Virtualization (react-window)
typescript
import { VariableSizeList } from 'react-window';

function MessageList({ messages }) {
  const getItemSize = (index) => {
    // Dynamic heights based on content
    return messages[index].text.length > 100 ? 80 : 50;
  };

  return (
    <VariableSizeList
      height={600}
      itemCount={messages.length}
      itemSize={getItemSize}
      width="100%"
    >
      {({ index, style }) => (
        <div style={style}>
          <Message message={messages[index]} />
        </div>
      )}
    </VariableSizeList>
  );
}
Pattern 5: Code Splitting with React.lazy
typescript
// Route-based splitting
const routes = [
  { path: '/home', component: lazy(() => import('./Home')) },
  { path: '/about', component: lazy(() => import('./About')) },
  { path: '/contact', component: lazy(() => import('./Contact')) }
];

// Component-based splitting
const HeavyChart = lazy(() => import('./HeavyChart'));

function Dashboard() {
  const [showChart, setShowChart] = useState(false);

  return (
    <div>
      <button onClick={() => setShowChart(true)}>Show Chart</button>

      {showChart && (
        <Suspense fallback={<Spinner />}>
          <HeavyChart />
        </Suspense>
      )}
    </div>
  );
}

Production Checklist

□ Profiler analysis completed (identified slow components)
□ Large lists use virtualization (&gt;100 items)
□ Routes code-split with React.lazy
□ Heavy components lazy-loaded
□ Callbacks memoized with useCallback
□ Expensive computations use useMemo
□ Pure components wrapped in React.memo
□ Bundle analyzed (no duplicate dependencies)
□ Tree-shaking enabled (ESM imports)
□ Images optimized and lazy-loaded
□ Lighthouse score &gt;90
□ Time to Interactive &lt;3 seconds

When to Use vs Avoid

ScenarioOptimize?
Rendering 1000+ list items✅ Yes - virtualize
Sorting/filtering large arrays✅ Yes - useMemo
Passing callbacks to memoized children✅ Yes - useCallback
String concatenation❌ No - fast enough
Simple arithmetic❌ No - don't memoize
10-item list❌ No - premature optimization

References

  • /references/profiling-guide.md - How to use React DevTools Profiler
  • /references/bundle-optimization.md - Reduce bundle size strategies
  • /references/memory-leaks.md - Detect and fix memory leaks

Scripts

  • scripts/performance_audit.ts - Automated performance checks
  • scripts/bundle_analyzer.sh - Analyze and visualize bundle

This skill guides: React performance optimization | Memoization | Virtualization | Code splitting | Bundle optimization | Profiling

© curiositech, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 6 other files (scripts, references) in .claude/skills/react-performance-optimizer of curiositech/some_claude_skills.

  • SKILL.md
  • .claude-plugin/plugin.json
  • references/bundle-optimization.md
  • references/memory-leaks.md
  • references/profiling-guide.md
  • scripts/bundle_analyzer.sh
  • scripts/performance_audit.ts

Open the folder on GitHubat commit 6713fc7

Compare with similar skills

React Performance Optimizer next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

React Performance Optimizer compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
React Performance Optimizer this skillcuriositech/some_claude_skills243—~2.8kAutomated safety check: PassMIT
React Doctormakeplane/plane60k12 repos~657Automated safety check: PassAGPL-3.0
React Frontend Development Guidelinesdiet103/claude-code-infrastructure-showcase10k2 repos~2.9kAutomated safety check: PassMIT
Core Web VitalsvmDeshpande/ai-agent-automation1784 repos~3.6kAutomated safety check: PassMIT
Reduce Bundle Sizekcsujeet/ilamy-calendar351—~2.9kAutomated safety check: PassMIT
Shader for Interfacesv2space-labs/shader-for-interfaces115—~3.1kAutomated safety check: PassMIT

Similar skills

  • React Doctor

    makeplane/plane

    Scans React code for lint, accessibility, bundle size and architecture issues, reports a health score and checks that changes do not lower it.

    60k GitHub starsUsed in 12 repos~657 tokens
    Frontend & DesignAuto-check passed
  • React Frontend Development Guidelines

    diet103/claude-code-infrastructure-showcase

    Guidelines for React 18 and TypeScript apps covering Suspense data fetching, lazy loading, feature folders, MUI v7 styling, TanStack Router and performance.

    10k GitHub starsUsed in 2 repos~2.9k tokens
    Frontend & DesignAuto-check passed
  • Core Web Vitals

    vmDeshpande/ai-agent-automation

    Optimize Core Web Vitals (LCP, INP, CLS) for better page experience and search ranking.

    178 GitHub starsUsed in 4 repos~3.6k tokens
    Frontend & DesignAuto-check passed
  • Reduce Bundle Size

    kcsujeet/ilamy-calendar

    Systematically reduce the shipped bundle size of a JS/TS library without sacrificing code readability or breaking consumer APIs.

    351 GitHub stars~2.9k tokensUpdated 4 days ago
    Frontend & DesignAuto-check passed
  • Shader for Interfaces

    v2space-labs/shader-for-interfaces

    Decides whether an interface effect belongs in CSS, SVG, Canvas 2D, WebGL or WebGPU, then builds, debugs and visually verifies focused GPU effects inside product UIs.

    115 GitHub stars~3.1k tokensUpdated 1 mo ago
    Frontend & DesignAuto-check passed
  • Ssr Boost Migrate

    Lomray-Software/vite-ssr-boost

    Migrate an existing Vite and React Router SPA to vite-ssr-boost SSR in Data mode, preserving route objects and checking streaming, hydration, bundle size, and deployment readiness.

    118 GitHub stars~2.3k tokensUpdated 15 days ago
    Frontend & DesignAuto-check passed

More from curiositech/some_claude_skills

All 108 skills in this repo
  • Crisis Detection Intervention AI

    curiositech/some_claude_skills

    Detect crisis signals in user content using NLP, mental health sentiment analysis, and safe intervention protocols.

    243 GitHub starsUsed in 3 repos~3.8k tokens
    Auto-check passed
  • Form Validation Architect

    curiositech/some_claude_skills

    End-to-end form handling with react-hook-form, Zod schemas, validation patterns, error messaging, field arrays, and multi-step wizards.

    243 GitHub stars~3.8k tokensUpdated 1 mo ago
    Auto-check passed
  • Competitive Cartographer

    curiositech/some_claude_skills

    Strategic analyst that maps competitive landscapes, identifies white space opportunities, and provides positioning recommendations.

    243 GitHub starsUsed in 1 repo~1.3k tokens
    Auto-check passed
  • GitHub Actions Pipeline Builder

    curiositech/some_claude_skills

    Build production CI/CD pipelines with GitHub Actions. An agent skill from curiositech/some_claude_skills.

    243 GitHub stars~2.8k tokensUpdated 1 mo ago
    Auto-check: notes
  • Computer Vision Pipeline

    curiositech/some_claude_skills

    Build production computer vision pipelines for object detection, tracking, and video analysis.

    243 GitHub starsUsed in 1 repo~4k tokens
    Auto-check passed
  • Design Archivist

    curiositech/some_claude_skills

    Long-running design anthropologist that builds comprehensive visual databases from 500-1000 real-world examples, extracting color palettes, typography patterns, layout systems, and interaction…

    243 GitHub starsUsed in 1 repo~1.6k tokens
    Auto-check passed

Works with

Questions about React Performance Optimizer

What does React Performance Optimizer do?

Optimize React apps for 60fps performance. An agent skill from curiositech/some_claude_skills. React Performance Optimizer is an agent skill from curiositech/some_claude_skills. Optimize React apps for 60fps performance.

When should I use React Performance Optimizer?

React Performance Optimizer fits situations like: tasks that involve Web performance.

How do I install React Performance Optimizer in Claude Code?

Run `npx skills add curiositech/some_claude_skills --skill react-performance-optimizer -a claude-code`. Or copy the skill folder (.claude/skills/react-performance-optimizer in curiositech/some_claude_skills) into .claude/skills/react-performance-optimizer in your project. Claude Code loads it when a task matches its description.

How do I install React Performance Optimizer in Codex?

Run `npx skills add curiositech/some_claude_skills --skill react-performance-optimizer -a codex`. Or copy the skill folder (.claude/skills/react-performance-optimizer in curiositech/some_claude_skills) into .agents/skills/react-performance-optimizer in your project. Codex loads it when a task matches its description.

Can I use React Performance Optimizer in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add curiositech/some_claude_skills --skill react-performance-optimizer -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/react-performance-optimizer, .gemini/skills/react-performance-optimizer, .github/skills/react-performance-optimizer and .opencode/skills/react-performance-optimizer in your project.

What does React Performance Optimizer need to run?

Going by SKILL.md and its folder, React Performance Optimizer needs a shell and TypeScript for the scripts in its folder. Our summary lists: Node.js; A Bash shell. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(npm:*).

Does React Performance Optimizer access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is React Performance Optimizer safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does React Performance Optimizer use?

React Performance Optimizer is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does React Performance Optimizer use?

About 2.8k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 9.7k tokens, read only when the agent opens those files.

What are the alternatives to React Performance Optimizer?

Skills that share tags, products or a category with React Performance Optimizer: React Doctor (makeplane/plane, 60k stars), React Frontend Development Guidelines (diet103/claude-code-infrastructure-showcase, 10k stars), Core Web Vitals (vmDeshpande/ai-agent-automation, 178 stars) and Reduce Bundle Size (kcsujeet/ilamy-calendar, 351 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains React Performance Optimizer?

curiositech (a GitHub organization) maintains it in curiositech/some_claude_skills, which has 243 GitHub stars. The repository holds 108 skills in this directory. The repository was last updated on September 6, 2026.

Source: curiositech/some_claude_skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.