Knowledge base from the official React 19 documentation (react.dev) — Learn guides, API reference (Hooks/Components/APIs), React DOM, React Compiler, React Server Components directives, and the Rules of React. Use when building or debugging React components, choosing between similar Hooks (useEffect vs useLayoutEffect, useMemo vs useCallback, useTransition vs useDeferredValue), looking up a Hook/API signature, deciding server vs. client component boundaries, or diagnosing a Rules-of-Hooks/purity violation.
Package: react, react-dom | Chapters: 116 (41 Learn + 4 Compiler + 2 ESLint + 44 API Reference + 1 Compiler Config + 17 React DOM + 4 RSC Directives + 3 Rules of React) | Generated: 2026-08-25
useEffect, createRoot, Suspense-style topics; I find and read the matching chapterch053; I load that specific chapterpatterns.md (techniques) and cheatsheet.md (decision rules) first; they cover the recurring judgment callsWhen you ask about a topic not covered in Core Patterns below, I will read the relevant chapter file before answering.
Rendering must be pure (Ch 18, Ch 114). No side effects, no mutation of anything that predates the current render — this single rule underlies Strict Mode's double-invoke behavior, React Compiler's automatic memoization, and why state/props are treated as read-only snapshots (Ch 23).
Never mutate state — always replace it. Objects need a spread-and-override (Ch 25); arrays need map/filter/spread instead of push/splice (Ch 26). This is what lets React detect a change at all.
State is a snapshot fixed within one render (Ch 23). Calling a setter never changes the value during the render/handler that called it — only the next render sees the update. When several updates to the same value must compound in one handler, use the updater-function form (setX(x => x + 1), Ch 24).
Effects synchronize with the outside world; event handlers respond to interactions (Ch 20, Ch 36, Ch 37). Before writing useEffect, check Ch 37 — a large share of "necessary" Effects are actually derived values (compute during render) or interaction logic (belongs in a handler).
Hooks: top-level only, same order every render, only from component/Hook bodies (Ch 115-116). This is mechanical, not stylistic — React tracks Hook state by call position. use (Ch 91) is the sole documented exception.
key controls identity, not just list rendering (Ch 17, Ch 30). Same component type at the same tree position preserves state across renders; changing key forces a full remount — the standard deliberate "reset this component" technique.
Server vs. Client is a directive, not a runtime check. No directive = Server Component by default in an RSC app (Ch 110); 'use client' (Ch 112) opts a subtree into browser execution; 'use server' (Ch 113) marks a function as a client-callable, server-only network boundary. Props/arguments crossing either boundary must be serializable.
Prefer derived values and lifted state over redundant/duplicated state (Ch 28, Ch 3). If a value can be computed from existing props/state at render time, don't also store it — this is the single most common source of state-sync bugs.
React Compiler (Ch 42) automates most manual useMemo/useCallback/memo where it can prove the Rules of React are followed — existing manual memoization stays valid, but a codebase clean under eslint-plugin-react-hooks's full rule set (Ch 46-47) is largely compiler-ready by construction.
| # | Title | Key Concepts |
|---|---|---|
| ch001 | Quick Start | components, JSX, useState, lifting state up |
| ch002 | Tutorial: Tic-Tac-Toe | lifting state, immutable history, time travel |
| ch003 | Thinking in React | 5-step process, component hierarchy, state placement |
| ch004 | Installation | try React, framework vs. from-scratch vs. existing project |
| ch005 | Add React to an Existing Project | partial mounting, createRoot, incremental adoption |
| ch006 | Build a React App from Scratch | Vite/Parcel/Rsbuild, routing, data fetching, rendering strategy |
| ch007 | Creating a React App | Next.js, React Router, Expo, Server Components |
| ch008 | Editor Setup | ESLint, eslint-plugin-react-hooks, Prettier |
| ch009 | Using TypeScript | typing props, Hooks, ComponentProps utility type |
| ch010 | React Developer Tools | Components/Profiler panels, standalone devtools |
| # | Title | Key Concepts |
|---|---|---|
| ch011 | Your First Component | capitalized names, never nest definitions |
| ch012 | Importing and Exporting Components | default vs. named exports |
| ch013 | Writing Markup with JSX | single root, close tags, camelCase |
| ch014 | JavaScript in JSX with Curly Braces | {} escape hatch, double-curly style objects |
| ch015 | Passing Props to a Component | destructuring, defaults, spread, children |
| ch016 | Conditional Rendering | if/ternary/&&, the && number pitfall |
| ch017 | Rendering Lists | map/filter, key rules |
| ch018 | Keeping Components Pure | purity, side effects, Strict Mode |
| ch019 | Understanding Your UI as a Tree | render tree vs. module dependency tree |
| # | Title | Key Concepts |
|---|---|---|
| ch020 | Responding to Events | onClick, stopPropagation, preventDefault |
| ch021 | State: A Component's Memory | useState mechanics, per-instance isolation |
| ch022 | Render and Commit | trigger/render/commit, DOM diffing |
| ch023 | State as a Snapshot | fixed values within a render |
| ch024 | Queueing a Series of State Updates | batching, updater functions |
| ch025 | Updating Objects in State | spread, read-only state |
| ch026 | Updating Arrays in State | non-mutating array methods |
| # | Title | Key Concepts |
|---|---|---|
| ch027 | Reacting to Input with State | declarative UI, visual states |
| ch028 | Choosing the State Structure | grouping, redundancy, duplication, nesting |
| ch029 | Sharing State Between Components | lifting state up, single source of truth |
| ch030 | Preserving and Resetting State | tree position, key-based reset |
| ch031 | Extracting State Logic into a Reducer | actions, pure reducers |
| ch032 | Passing Data Deeply with Context | createContext, useContext, prop drilling |
| ch033 | Scaling Up with Reducer and Context | split state/dispatch contexts |
| # | Title | Key Concepts |
|---|---|---|
| ch034 | Referencing Values with Refs | useRef, refs vs. state |
| ch035 | Manipulating the DOM with Refs | focus, scroll, DOM ref timing |
| ch036 | Synchronizing with Effects | useEffect shape, cleanup, dependencies |
| ch037 | You Might Not Need an Effect | derived state, event logic, key-based reset |
| ch038 | Lifecycle of Reactive Effects | per-render Effect model, reactive values |
| ch039 | Separating Events from Effects | useEffectEvent, non-reactive reads |
| ch040 | Removing Effect Dependencies | unstable object/function deps |
| ch041 | Reusing Logic with Custom Hooks | custom Hook rules, shared logic vs. shared state |
| # | Title | Key Concepts |
|---|---|---|
| ch042 | React Compiler — Introduction | automatic memoization |
| ch043 | React Compiler — Installation | Babel plugin, ESLint integration |
| ch044 | React Compiler — Incremental Adoption | directory rollout, "use memo", gating |
| ch045 | React Compiler — Debugging and Troubleshooting | "use no memo" isolation workflow |
| # | Title | Key Concepts |
|---|---|---|
| ch046 | Setup & Configuration | recommended preset, gating, globals |
| ch047 | Rules Reference | rules-of-hooks, exhaustive-deps, purity, immutability |
| # | Title | Key Concepts |
|---|---|---|
| ch048 | useActionState | Actions, dispatchAction, isPending |
| ch049 | useCallback | stable function identity |
| ch050 | useContext | nearest-provider resolution |
| ch051 | useDebugValue | custom Hook DevTools labels |
| ch052 | useDeferredValue | lagging value, pairs with memo |
| ch053 | useEffect | setup/cleanup, dependency array |
| ch054 | useEffectEvent | non-reactive Effect logic |
| ch055 | useId | SSR-safe accessibility IDs |
| ch056 | useImperativeHandle | custom ref handle |
| ch057 | useInsertionEffect | CSS-in-JS pre-layout injection |
| ch058 | useLayoutEffect | synchronous pre-paint measurement |
| ch059 | useMemo | cached calculation |
| ch060 | useOptimistic | optimistic UI, Actions |
| ch061 | useReducer | dispatch, lazy init |
| ch062 | useRef | mutable box, DOM refs |
| ch063 | useState | initializer function, updater form |
| ch064 | useSyncExternalStore | external store subscription, tear-safety |
| ch065 | useTransition | low-priority updates, Actions |
| # | Title | Key Concepts |
|---|---|---|
| ch066 | Activity | hidden-but-mounted subtrees |
| ch067 | Fragment | grouping without a DOM node |
| ch068 | Profiler | programmatic render timing |
| ch069 | StrictMode | dev-only double-invoke checks |
| ch070 | Suspense | fallback coordination |
| ch071 | ViewTransition | native View Transitions API |
| # | Title | Key Concepts |
|---|---|---|
| ch072 | act | test-only update flushing |
| ch073 | addTransitionType | tagging transitions for ViewTransition |
| ch074 | cache | per-server-request memoization (RSC) |
| ch075 | cacheSignal | abort signal for cached work (RSC) |
| ch076 | captureOwnerStack | dev-only owner stack for tooling |
| ch077 | Children | map/count/only/toArray over children |
| ch078 | cloneElement | legacy element cloning |
| ch079 | Component (legacy) | class lifecycle, error boundaries |
| ch080 | createContext | Context object creation |
| ch081 | createElement | what JSX compiles to |
| ch082 | createRef | class-component-only ref creation |
| ch083 | experimental_taintObjectReference | RSC object leak protection |
| ch084 | experimental_taintUniqueValue | RSC secret-value leak protection |
| ch085 | forwardRef | legacy ref forwarding |
| ch086 | isValidElement | React-element type guard |
| ch087 | lazy | code-splitting, requires Suspense |
| ch088 | memo | shallow prop comparison, skip re-render |
| ch089 | PureComponent (legacy) | class-component shallow comparison |
| ch090 | startTransition | standalone transition function |
| ch091 | use | conditional promise/Context reads |
| # | Title | Key Concepts |
|---|---|---|
| ch092 | Configuration & Directives Reference | target, panicThreshold, "use memo"/"use no memo" |
| # | Title | Key Concepts |
|---|---|---|
| ch093 | React DOM — Client Overview | createRoot vs. hydrateRoot |
| ch094 | createRoot | client-only root attachment |
| ch095 | hydrateRoot | SSR hydration, mismatch handling |
| ch096 | Common Components | className, style, dangerouslySetInnerHTML |
| ch097 | <form> | function action, Server Function integration |
| ch098 | <input> | controlled vs. uncontrolled |
| ch099 | <select> | value on the select, not the option |
| ch100 | <textarea> | value/defaultValue, not children |
| ch101 | <option>, <progress>, <title> | selection ownership, indeterminate, hoisted title |
| ch102 | createPortal | DOM escape, React-tree event bubbling |
| ch103 | flushSync | forced synchronous commit |
| ch104 | useFormStatus | nested form pending status |
| ch105 | Resource Preloading APIs | preconnect, preload, preinit family |
| ch106 | renderToPipeableStream | Node streaming SSR |
| ch107 | renderToReadableStream | Web Streams SSR |
| ch108 | Server Static & Resume APIs | renderToString, resume |
| ch109 | Static Prerender APIs | prerender, resumeAndPrerender |
| # | Title | Key Concepts |
|---|---|---|
| ch110 | Server Components | server-only rendering, zero client bundle |
| ch111 | Server Functions | 'use server', callable from client |
| ch112 | 'use client' | client boundary directive |
| ch113 | 'use server' | Server Function directive mechanics |
| # | Title | Key Concepts |
|---|---|---|
| ch114 | Components and Hooks Must Be Pure | idempotency, no side effects in render |
| ch115 | React Calls Components and Hooks | never call directly, always via JSX |
| ch116 | Rules of Hooks | top-level only, call-order tracking |
This skill covers the official React 19 documentation (react.dev) as of the fetch date in the source: the Learn guides, the full API reference (Hooks, Components, APIs, React DOM), React Compiler, the ESLint plugin's rules, React Server Components directives, and the Rules of React.
Related skills in this library: nextjs-docs covers Next.js, the full-stack framework built on React that currently has the most complete React Server Components implementation (Ch 7, Ch 110) — when working in a Next.js App Router codebase, consult nextjs-docs for routing/data-fetching/deployment concerns and react-docs for the underlying component/Hook/rendering-model behavior. react-hook-form-docs covers a form library built on React Hooks — consult it for form-specific state management beyond what <form action>/useActionState/useFormStatus (Ch 97, Ch 48, Ch 104) cover natively.
The source aggregates 174 individual react.dev pages; a small number of purely navigational "section overview" stub pages (e.g. "Built-in React Hooks", "React DOM APIs") were folded into their group's chapter intros here rather than kept as standalone chapters, and a handful of very short, closely related reference pages (ESLint rules, React Compiler config options, resource-preloading functions, small React DOM elements, server static/prerender API variants) were consolidated into single denser chapters rather than one chapter per page — each consolidation is noted in that chapter's own scope.