react-next-performance-optimization

react-next-performance-optimization is a skill for Codex from jeremylongworth-source/AgentSkills. It costs 76 tokens per session (553 once invoked), scanned A, original, MIT.

A performance review guide for React and Next.js web applications, which are JavaScript tools for building user interfaces and websites.

In plain words
What is it for?
It covers bundle size, browser performance, server rendering, data fetching, caching, re-renders, images, fonts, scripts, and Core Web Vitals, a set of metrics for loading and user interaction.
Why use it?
It helps locate the measured cause of slow pages, interactions, builds, or routes before suggesting changes.

Skill for Codex

Written for Codex: agents/openai.yaml present. Also seen: mentions Codex.

Good fit It covers bundle size, browser performance, server rendering, data fetching, caching, re-renders, images, fonts, scripts, and Core Web Vitals, a set of metrics for loading and user interaction.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/jeremylongworth-source/agentskills/react-next-performance-optimization
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add jeremylongworth-source/AgentSkills --skill react-next-performance-optimization
Clone the repo
git clone --depth 1 https://github.com/jeremylongworth-source/AgentSkills

Made for: Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for react-next-performance-optimization

README.md
[![agentmods](https://agentmods.dev/badge/skills/jeremylongworth-source/agentskills/react-next-performance-optimization/github.svg)](https://agentmods.dev/skills/jeremylongworth-source/agentskills/react-next-performance-optimization)
Your own site
<a href="https://agentmods.dev/skills/jeremylongworth-source/agentskills/react-next-performance-optimization"><img src="https://agentmods.dev/badge/skills/jeremylongworth-source/agentskills/react-next-performance-optimization/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for react-next-performance-optimization

Your own site · 80×15
<a href="https://agentmods.dev/skills/jeremylongworth-source/agentskills/react-next-performance-optimization"><img src="https://agentmods.dev/badge/skills/jeremylongworth-source/agentskills/react-next-performance-optimization.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 76 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 553 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00076 $0.00553
Opus 5 $0.00038 $0.00277
Sonnet 5 $0.00015 $0.00111
Haiku 4.5 $0.00008 $0.00055

Measured 7d ago against content hash ad6653fc9260, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

react-next-performance-optimization scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/react-next-performance-optimization/SKILL.md · 45 lines

How it starts

The opening of the file, as written. The whole thing — 45 lines — stays where its author put it; the contents beside it link to each section on GitHub.

React Next Performance Optimization

Core Workflow

  1. Identify framework version, router mode, rendering strategy, deployment target, slow user flow, and target metric.
  2. Measure before changing: build output, bundle analyzer, browser performance traces, React Profiler, Lighthouse/Web Vitals, server logs, or user-reported reproduction.
  3. Classify bottlenecks by layer: network, server/rendering, data fetching/cache, JavaScript bundle, hydration, re-rendering, layout/paint, images/fonts/scripts, third-party code, or backend.
  4. Fix highest-impact verified issues first. Avoid speculative memoization and broad rewrites.
  5. Re-measure after each meaningful change and record the before/after evidence.
  6. Leave a prevention note: what pattern caused the issue, how to avoid it, and what metric/test should catch recurrence.

Optimization Priorities

  • Next.js: prefer Server Components by default, keep "use client" boundaries narrow, use framework image/font/script/lazy-loading tools, and understand caching/revalidation before changing data flow.
  • React: reduce unnecessary state lifting, unstable props, expensive renders, effect loops, and avoidable context churn; use memo, useMemo, and useCallback only when they solve a measured problem or preserve stable references intentionally.
  • Bundles: inspect large dependencies, duplicate packages, client-only imports, heavy charts/editors/maps, and dynamic imports.
  • Runtime: inspect long tasks, hydration cost, layout shifts, input delay, memory churn, and repeated network work.
  • Core Web Vitals: optimize LCP, INP, and CLS with user-flow evidence, not only lab scores.

Freshness Rule

Verify current official React, Next.js, and web.dev guidance before making version-sensitive recommendations about React Compiler, Server Components, caching APIs, Turbopack, bundle analysis, or Web Vitals thresholds.

Deliverable Shape

For performance work, provide:

  • Baseline evidence collected or missing
  • Bottleneck classification
  • Prioritized findings
  • Recommended changes with expected impact
  • Changes made, if editing
  • Before/after verification
  • Prevention notes and remaining risks

Read the full file on GitHub · 45 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 45 lines · 76 tokens per session scan A ad6653fc9260

Subscribe to this mod's changes

react-next-performance-optimization is a skill published in the GitHub repository jeremylongworth-source/AgentSkills (1 stars, last pushed 8d ago), licensed MIT. It adds 76 tokens to every session and 553 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.