react-coding

react-coding is a skill for Claude Code from Dynokostya/just-works. It costs 46 tokens per session (2,969 once invoked), scanned A, original, Apache-2.0.

A set of coding rules for React, a JavaScript library for building user interfaces, when editing JSX or TSX files. It covers hooks, state, components, rendering efficiency, security, and common mistakes.

In plain words
What is it for?
Use it when creating or changing React components, hooks, state handling, memoization, or related application code.
Why use it?
It helps avoid unnecessary renders, incorrect effect usage, and other React bugs while following the project's existing conventions.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

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/dynokostya/just-works/react-coding
Any agent
npx skills add Dynokostya/just-works --skill react-coding
Clone the repo
git clone --depth 1 https://github.com/Dynokostya/just-works

Made for: Claude Code.

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-coding

README.md
[![agentmods](https://agentmods.dev/badge/skills/dynokostya/just-works/react-coding.svg)](https://agentmods.dev/skills/dynokostya/just-works/react-coding)
Your own site
<a href="https://agentmods.dev/skills/dynokostya/just-works/react-coding"><img src="https://agentmods.dev/badge/skills/dynokostya/just-works/react-coding.svg" alt="Measured on agentmods" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,969 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.1 $0.00046 $0.02969
Opus 5 $0.00023 $0.01484
Sonnet 5 $0.00009 $0.00594
Haiku 4.5 $0.00005 $0.00297

Measured yesterday against content hash e9f3a9549fa1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

react-coding 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 yesterday.

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.

.claude/skills/react-coding/SKILL.md · 286 lines

How it starts

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

React Coding

Match the project's existing conventions. When uncertain, read 2-3 existing components to infer the local style. Check tsconfig.json for strictness settings, package.json for React version, and framework config (Next.js, Remix, Vite) for routing and rendering conventions. These defaults apply only when the project has no established convention.

Never rules

These are unconditional. They prevent bugs, wasted renders, and vulnerabilities regardless of project style.

  • Never useEffect for derived state -- if a value can be computed from props or state, compute it during render. useEffect + setState for derivable values causes an unnecessary extra render cycle. This is the most common React mistake.
// Wrong: extra render cycle for a value computable from props
const [fullName, setFullName] = useState("");
useEffect(() => {
  setFullName(`${first} ${last}`);
}, [first, last]);

// Correct: compute during render
const fullName = `${first} ${last}`;
  • Never useEffect for event-driven logic -- user-triggered actions belong in event handlers, not effects keyed to state flags. Effects are for synchronizing with external systems.
// Wrong: effect triggered by state flag
const [submitted, setSubmitted] = useState(false);
useEffect(() => {
  if (submitted) sendAnalytics();
}, [submitted]);

// Correct: logic in the event handler
function handleSubmit() {
  sendAnalytics();
  navigate("/done");
}
  • Never fetch data in useEffect without cleanup -- missing AbortController causes race conditions on rapid prop changes. Prefer TanStack Query or framework data fetching over raw useEffect fetching entirely.
// Wrong: no abort, race condition on rapid userId changes
useEffect(() => {
  fetch(`/api/users/${userId}`).then(r => r.json()).then(setUser);
}, [userId]);

// Correct: AbortController for cleanup, error captured in state
// (rethrowing inside .catch would just create an unhandled rejection)
useEffect(() => {
  const controller = new AbortController();
  fetch(`/api/users/${userId}`, { signal: controller.signal })
    .then(r => r.json())
    .then(setUser)
    .catch(e => { if (e.name !== "AbortError") setError(e); });
  return () => controller.abort();
}, [userId]);

// Best: TanStack Query handles caching, deduplication, and cancellation
const { data: user } = useQuery({
  queryKey: ["user", userId],
  queryFn: () => fetchUser(userId),
});

Read the full file on GitHub · 286 lines

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. yesterday First seen · 286 lines · 46 tokens per session scan A e9f3a9549fa1

Subscribe to this mod's changes

react-coding is a skill published in the GitHub repository Dynokostya/just-works (14 stars, last pushed yesterday), licensed Apache-2.0. It adds 46 tokens to every session and 2,969 once invoked, about $0.0002 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-04.

Related

Other skills, from other repositories

v8-jit

V8 JIT optimization patterns for writing high-performance JavaScript in Next.js server internals. Use when writing or reviewing hot-path code in app-render, stream-utils, routing, caching, or any per-request code path. Covers hidden classes / shapes, monomorphic call sites, inline caches, megamorphic deopt, closure…

vercel/next.js · 88 tokens

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…

chakra-ui/chakra-ui · 214 tokens

material-ui-tailwind

Integrates Material UI with Tailwind CSS v4 using cascade layers (enableCssLayer, @layer order) and documents Tailwind v3 interoperability (preflight, important, injectFirst, portals). Use when combining MUI with Tailwind utilities, slotProps className, or theme token bridges.

mui/material-ui · 67 tokens

verify

Use when you want to validate changes before committing, or when you need to check all React contribution requirements.

react/react · 23 tokens

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.

zebbern/claude-code-guide · 74 tokens

git-safety

Git safety rules. INVOKE WHEN: git push, force push, git reset, git clean, destructive git, push force, reset hard. NEVER force push or do destructive git operations.

tamagui/tamagui · 0 tokens