react-docs

react-docs is a skill for Claude Code, Codex from pledgeandgrow/pledge-skills. It costs 68 tokens per session (1,126 once invoked), scanned A, original, MIT.

A reference for React 19, the JavaScript library for building user interfaces from reusable components. It covers hooks, forms, context, Suspense, server components, and other built-in React features.

In plain words
What is it for?
Use it when building components, managing state and effects, handling forms, sharing data, loading content gradually, or working with React server and concurrent features.
Why use it?
It gives you a single place to check how React APIs work and which patterns apply when writing or reviewing React code.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/pledgeandgrow/pledge-skills/react
Any agent
npx skills add pledgeandgrow/pledge-skills --skill react
Clone the repo
git clone --depth 1 https://github.com/pledgeandgrow/pledge-skills

Made for: Claude Code, 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-docs

README.md
[![agentmods](https://agentmods.dev/badge/skills/pledgeandgrow/pledge-skills/react.svg)](https://agentmods.dev/skills/pledgeandgrow/pledge-skills/react)
Your own site
<a href="https://agentmods.dev/skills/pledgeandgrow/pledge-skills/react"><img src="https://agentmods.dev/badge/skills/pledgeandgrow/pledge-skills/react.svg" alt="Measured on agentmods" height="20"></a>
Per session 68 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,126 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00068 $0.01126
Opus 5 $0.00034 $0.00563
Sonnet 5 $0.00014 $0.00225
Haiku 4.5 $0.00007 $0.00113

Measured 4d ago against content hash 6b904396f50a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

react-docs 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 4d 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/SKILL.md · 152 lines

How it starts

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

React Expert (v19.x)

Official Documentation: https://react.dev/reference

Quick Reference

Topic File
State hooks: useState, useReducer state-hooks.md
Effect hooks: useEffect, useLayoutEffect, useInsertionEffect effect-hooks.md
Context: createContext, useContext, Provider pattern context.md
Ref hooks: useRef, useImperativeHandle ref-hooks.md
Performance: useMemo, useCallback, memo, PureComponent performance.md
Concurrent features: useTransition, useDeferredValue, useActionState, useOptimistic concurrent-features.md
Other hooks: useId, useSyncExternalStore, useDebugValue, use other-hooks.md
Suspense, lazy, streaming suspense.md
Built-in components: Fragment, StrictMode, Profiler, Suspense components.md
Forms: Actions, useFormStatus, progressive enhancement forms.md
React 19 new features react-19.md
Rules of React: purity, hooks rules, ESLint rules-of-react.md
Advanced patterns: compound, render props, HOCs, custom hooks advanced-patterns.md
React DOM: createRoot, hydration, portals, flushSync react-dom.md

Core Philosophy

React is a declarative UI library built on three principles:

  1. Components — Independent, reusable pieces of UI
  2. Props — Read-only data flow from parent to child
  3. State — Mutable data that triggers re-renders when changed

Component Types

// Function Component (recommended)
function Greeting({ name }: { name: string }) {
  return <h1>Hello, {name}</h1>
}

// With state
function Counter() {
  const [count, setCount] = useState(0)
  return <button onClick={() => setCount(c => c + 1)}>{count}</button>
}

Component Lifecycle

Mount → Render → Commit → (State Change → Re-render → Commit) → Unmount
        ↑                                          ↑
    useEffect (after paint)              useEffect cleanup → new effect
    useLayoutEffect (before paint)

Read the full file on GitHub · 152 lines

Files

What ships with it

14 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. 4d ago First seen · 152 lines · 68 tokens per session scan A 6b904396f50a

Subscribe to this mod's changes

react-docs is a skill published in the GitHub repository pledgeandgrow/pledge-skills (10 stars, last pushed 1mo ago), licensed MIT. It adds 68 tokens to every session and 1,126 once invoked, about $0.0003 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-08-31.

Related

Other skills, from other repositories