tsq-react

tsq-react is a skill for Claude Code, Codex from sonature-lab/timsquad. It costs 79 tokens per session (960 once invoked), scanned A, original, MIT.

A set of React development guidelines for building components and custom hooks. React is a JavaScript library for user interfaces; these guidelines cover component responsibility, data flow, and separating server data from browser state.

In plain words
What is it for?
Use it when creating or editing React components, managing state, writing custom hooks, or working in JSX and TSX files.
Why use it?
It helps keep React code consistent and easier to change by defining where interface logic and state should live.

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/sonature-lab/timsquad/tsq-react
Any agent
npx skills add sonature-lab/timsquad --skill tsq-react
Clone the repo
git clone --depth 1 https://github.com/sonature-lab/timsquad

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 tsq-react

README.md
[![agentmods](https://agentmods.dev/badge/skills/sonature-lab/timsquad/tsq-react.svg)](https://agentmods.dev/skills/sonature-lab/timsquad/tsq-react)
Your own site
<a href="https://agentmods.dev/skills/sonature-lab/timsquad/tsq-react"><img src="https://agentmods.dev/badge/skills/sonature-lab/timsquad/tsq-react.svg" alt="Measured on agentmods" height="20"></a>
Per session 79 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 960 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.00079 $0.00960
Opus 5 $0.00039 $0.00480
Sonnet 5 $0.00016 $0.00192
Haiku 4.5 $0.00008 $0.00096

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

Security

Grade A, and why

tsq-react 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.

templates/base/skills/tsq-react/SKILL.md · 90 lines

How it starts

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

React Development Guidelines

프로젝트 전체에서 일관된 React 컴포넌트 개발을 위한 컨벤션. 기본 스택: React Query, Zustand, React Hook Form + Zod. 프로젝트 설정(memory/conventions.md)으로 재정의 가능.

Philosophy

  • 컴포넌트는 단일 책임
  • UI와 로직 분리 (커스텀 훅)
  • Props로 명시적 데이터 흐름
  • 서버 상태와 클라이언트 상태 분리

Resources

25개 규칙 (TimSquad 3 + Vercel 22). 카테고리 인덱스: _sections.md

Priority Type Resource Description
CRITICAL rule async-parallel Promise.all 병렬 실행 (2-10x)
CRITICAL rule bundle-barrel-imports barrel import 피하기
HIGH rule component-conventions 컴포넌트 구조, export, 크기 제한
HIGH rule state-location 상태 관리 선택 기준
HIGH rule server-parallel-fetching 서버 병렬 fetch
HIGH rule rerender-memo React.memo 최적화
MEDIUM rule anti-patterns Props Drilling, useEffect 남용

Quick Rules

컴포넌트

  • 함수형 컴포넌트 + Props interface
  • named export (export function, default export 금지)
  • 200줄 이하
  • forwardRef로 ref 전달 지원

  • 커스텀 훅으로 로직 분리 (use 접두사)
  • 의존성 배열 정확히 관리
  • 함수형 setState로 stale closure 방지
  • 조건문/반복문 안에서 훅 호출 금지
  • useEffect 남용 금지 (파생 상태는 useMemo)

상태 관리

  • 서버 상태: React Query (TanStack Query)
  • 전역 UI 상태: Zustand
  • 로컬 상태: useState
  • 복잡한 로직: useReducer
  • 비싼 초기값: lazy init (useState(() => ...))
  • Props drilling 3단계 이상 → Context 또는 Zustand

성능 (vercel-react-best-practices 참조)

  • 리스트에 고유 key (index 금지)
  • Promise.all로 병렬 fetch
  • barrel import 피하기 (직접 import)
  • dynamic import로 무거운 컴포넌트 분리
  • content-visibility로 대량 리스트 최적화
  • toSorted()로 배열 불변성

  • React Hook Form + Zod (zodResolver)
  • onBlur 유효성 검사, submit 시 첫 에러 필드 포커스

Checklist

Priority Item
CRITICAL 함수형 컴포넌트 + Props 타입 정의
CRITICAL 커스텀 훅으로 로직 분리
CRITICAL 서버 상태는 React Query
CRITICAL Error Boundary로 에러 격리
CRITICAL Waterfall 제거 (Promise.all)
CRITICAL Barrel import 피하기
HIGH 의존성 배열 정확히 관리
HIGH 리스트에 고유 key (index 금지)
HIGH 폼은 React Hook Form + Zod
HIGH 함수형 setState 사용
HIGH Dynamic import 분리
MEDIUM 대량 리스트 가상화 / content-visibility
MEDIUM 불필요한 useEffect 제거
MEDIUM RSC 경계에서 필요한 데이터만 전달

Read the full file on GitHub · 90 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. 4d ago First seen · 90 lines · 79 tokens per session scan A 39b51ce2ee34

Subscribe to this mod's changes

tsq-react is a skill published in the GitHub repository sonature-lab/timsquad (11 stars, last pushed 7d ago), licensed MIT. It adds 79 tokens to every session and 960 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-08-30.

Related

Other skills, from other repositories

react-vendoring

React vendoring and react-server layer boundaries. Use when editing entry-base.ts, $$compiled.internal.d.ts, compiled/react packages, or taskfile.js copyvendorreact. Covers the entry-base.ts boundary (all react-server-dom-webpack/ imports must go through it), vendored React channels, type declarations, Turbopack remap…

vercel/next.js · 96 tokens

react-sync

Build local React changes in the bundle variants consumed by Next.js, sync them into a local Next.js checkout, and test the resulting integration. Use when working on React changes that need validation in Next.js, or when asked to run buildForNext, pnpm sync-react, or synchronize a React checkout with Next.js.

vercel/next.js · 67 tokens

shadcn

Manages shadcn components and projects — adding, searching, fixing, debugging, styling, and composing UI, including chat interfaces. Provides project context, component docs, and usage examples. Applies when working with shadcn/ui, component registries, presets, --preset codes, or any project with a components.json…

shadcn-ui/ui · 94 tokens

migrate-radix-to-base

Migrates React projects and components from Radix UI to Base UI. Use when asked to migrate from radix, move to base-ui, convert radix primitives, or switch a shadcn project's base library. Handles single components ("migrate accordion") and whole projects.

shadcn-ui/ui · 61 tokens

flags

How to add or modify Next.js experimental feature flags end-to-end. Use when editing config-shared.ts, config-schema.ts, define-env-plugin.ts, next-server.ts, export/worker.ts, or module.compiled.js. Covers type declaration, zod schema, build-time injection, runtime env plumbing, and the decision between runtime…

vercel/next.js · 77 tokens

theme-component

Add complete theme support for one Recharts component. Invoke with the component name, for example theme-component XAxis.

recharts/recharts · 27 tokens