Borrowing it
Nothing to install: this file belongs to mikeOnBreeze/cc-crossbeam. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/mikeOnBreeze/cc-crossbeam/main/.claude/skills/react-best-practices/SKILL.mdgit clone --depth 1 https://github.com/mikeOnBreeze/cc-crossbeamWrote 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.
[](https://agentmods.dev/skills/mikeonbreeze/cc-crossbeam/react-best-practices)<a href="https://agentmods.dev/skills/mikeonbreeze/cc-crossbeam/react-best-practices"><img src="https://agentmods.dev/badge/skills/mikeonbreeze/cc-crossbeam/react-best-practices.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00065 | $0.00795 |
| Opus 5 | $0.00032 | $0.00398 |
| Sonnet 5 | $0.00013 | $0.00159 |
| Haiku 4.5 | $0.00006 | $0.00080 |
Grade A, and why
react-best-practices 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 8d 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.
Copies of this mod
1 near-identical copy found in the catalogue:
- react-best-practices — 88% identical, 22 lines differ
How it starts
The opening of the file, as written. The whole thing — 107 lines — stays where its author put it; the contents beside it link to each section on GitHub.
React Best Practices
Overview
Comprehensive performance optimization guide for React and Next.js applications, containing 40+ rules across 8 categories. Rules are prioritized by impact to guide automated refactoring and code generation.
When to Apply
Reference these guidelines when:
- Writing new React components or Next.js pages
- Implementing data fetching (client or server-side)
- Reviewing code for performance issues
- Refactoring existing React/Next.js code
- Optimizing bundle size or load times
Priority-Ordered Guidelines
Rules are prioritized by impact:
| Priority | Category | Impact |
|---|---|---|
| 1 | Eliminating Waterfalls | CRITICAL |
| 2 | Bundle Size Optimization | CRITICAL |
| 3 | Server-Side Performance | HIGH |
| 4 | Client-Side Data Fetching | MEDIUM-HIGH |
| 5 | Re-render Optimization | MEDIUM |
| 6 | Rendering Performance | MEDIUM |
| 7 | JavaScript Performance | LOW-MEDIUM |
| 8 | Advanced Patterns | LOW |
Quick Reference
Critical Patterns (Apply First)
Eliminate Waterfalls:
- Defer await until needed (move into branches)
- Use
Promise.all()for independent async operations - Start promises early, await late
- Use
better-allfor partial dependencies - Use Suspense boundaries to stream content
Reduce Bundle Size:
- Avoid barrel file imports (import directly from source)
- Use
next/dynamicfor heavy components - Defer non-critical third-party libraries
- Preload based on user intent
High-Impact Server Patterns
- Use
React.cache()for per-request deduplication - Use LRU cache for cross-request caching
- Minimize serialization at RSC boundaries
- Parallelize data fetching with component composition
Medium-Impact Client Patterns
- Use SWR for automatic request deduplication
- Defer state reads to usage point
- Use lazy state initialization for expensive values
- Use derived state subscriptions
- Apply
startTransitionfor non-urgent updates
Rendering Patterns
- Animate SVG wrappers, not SVG elements directly
- Use
content-visibility: autofor long lists - Prevent hydration mismatch with inline scripts
- Use explicit conditional rendering (
? :not&&)
What ships with it
46 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.
- references/react-performance-guidelines.md 48 KB
- references/rules/_sections.md 1.5 KB
- references/rules/_template.md 631 B
- references/rules/advanced-event-handler-refs.md 960 B
- references/rules/advanced-use-latest.md 1.2 KB
- references/rules/async-api-routes.md 1.1 KB
- references/rules/async-defer-await.md 2.0 KB
- references/rules/async-dependencies.md 942 B
- references/rules/async-parallel.md 654 B
- references/rules/async-suspense-boundaries.md 1.6 KB
- references/rules/bundle-barrel-imports.md 2.3 KB
- references/rules/bundle-conditional.md 870 B
- references/rules/bundle-defer-third-party.md 922 B
- references/rules/bundle-dynamic-imports.md 791 B
- references/rules/bundle-preload.md 1.1 KB
- references/rules/client-event-listeners.md 1.9 KB
- references/rules/client-swr-dedup.md 1.1 KB
- references/rules/js-batch-dom-css.md 1.9 KB
- references/rules/js-cache-function-results.md 1.9 KB
- references/rules/js-cache-property-access.md 532 B
- references/rules/js-cache-storage.md 1.6 KB
- references/rules/js-combine-iterations.md 753 B
- references/rules/js-early-exit.md 1.1 KB
- references/rules/js-hoist-regexp.md 994 B
- references/rules/js-index-maps.md 837 B
- references/rules/js-length-check-first.md 1.7 KB
- references/rules/js-min-max-loop.md 2.1 KB
- references/rules/js-set-map-lookups.md 532 B
- references/rules/js-tosorted-immutable.md 1.7 KB
- references/rules/rendering-activity.md 564 B
- references/rules/rendering-animate-svg-wrapper.md 1.2 KB
- references/rules/rendering-conditional-render.md 983 B
- references/rules/rendering-content-visibility.md 822 B
- references/rules/rendering-hoist-jsx.md 819 B
- references/rules/rendering-hydration-no-flicker.md 2.3 KB
- references/rules/rendering-svg-precision.md 591 B
- references/rules/rerender-defer-reads.md 973 B
- references/rules/rerender-dependencies.md 827 B
- references/rules/rerender-derived-state.md 724 B
- references/rules/rerender-lazy-state-init.md 2.0 KB
- references/rules/rerender-memo.md 935 B
- references/rules/rerender-transitions.md 1.0 KB
- references/rules/server-cache-lru.md 1011 B
- references/rules/server-cache-react.md 679 B
- references/rules/server-parallel-fetching.md 1.5 KB
- references/rules/server-serialization.md 826 B
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.
- 8d ago First seen · 107 lines · 65 tokens per session scan A f6e6e80abc3c
react-best-practices is a skill published in the GitHub repository mikeOnBreeze/cc-crossbeam (291 stars, last pushed 6mo ago), licensed MIT. It adds 65 tokens to every session and 795 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-30.
Other skills, from other repositories
react-patterns
React 18/19 patterns including hooks discipline, server/client component boundaries, Suspense + error boundaries, form actions, data fetching, state management decision trees, and accessibility-first composition. Use when writing or reviewing React components.
chakra-ui-builder
Build responsive, accessible UI components and layouts using Chakra UI v3, install or configure Chakra UI in new and existing projects, and design scalable themes using tokens, semantic tokens, recipes, and slot recipes. Use this skill whenever a user asks to build, create, or generate any UI component, page, form…
r3f-best-practices
React Three Fiber (R3F) and Poimandres ecosystem best practices. Use when writing, reviewing, or optimizing R3F code. Triggers on tasks involving @react-three/fiber, @react-three/drei, zustand, @react-three/postprocessing, @react-three/rapier, or leva.
assistant-ui-primitives
Guide for assistant-ui UI primitives - ThreadPrimitive, ComposerPrimitive, MessagePrimitive. Use when customizing chat UI components.
create-site
Creates a new Power Pages code site (SPA) using React, Angular, Vue, or Astro. Guides through the full process from initial concept to deployed site: requirements discovery, scaffolding, component planning, design, implementation, validation, and deployment. Use when the user wants to create, build, or scaffold a new…
fast-typescript-check
Keep www-sacred's TypeScript fast to type-check and fast to run. Use when touching the ASCII/canvas animation components (the only real per-frame code here), tightening type-check wall-clock, or auditing a change for runtime or compiler regressions. Scoped to this repo — a React 19 / Next.js 16 component library plus…