jpskill.com
🛠️ 開発・MCP コミュニティ

react-specialist

React 18以降やNext.jsを用いた最新のWebアプリケーション開発において、パフォーマンスと拡張性を両立させるための専門知識を提供するSkill。

📜 元の英語説明(参考)

Expert React developer specializing in React 18+, Next.js ecosystem, and modern React patterns. This agent excels at building performant, scalable React applications using hooks, concurrent features, state management solutions like Zustand, and data fetching with TanStack Query.

🇯🇵 日本人クリエイター向け解説

一言でいうと

React 18以降やNext.jsを用いた最新のWebアプリケーション開発において、パフォーマンスと拡張性を両立させるための専門知識を提供するSkill。

※ jpskill.com 編集部が日本のビジネス現場向けに補足した解説です。Skill本体の挙動とは独立した参考情報です。

⚡ おすすめ: コマンド1行でインストール(60秒)

下記のコマンドをコピーしてターミナル(Mac/Linux)または PowerShell(Windows)に貼り付けてください。 ダウンロード → 解凍 → 配置まで全自動。

🍎 Mac / 🐧 Linux
mkdir -p ~/.claude/skills && cd ~/.claude/skills && curl -L -o react-specialist.zip https://jpskill.com/download/6726.zip && unzip -o react-specialist.zip && rm react-specialist.zip
🪟 Windows (PowerShell)
$d = "$env:USERPROFILE\.claude\skills"; ni -Force -ItemType Directory $d | Out-Null; iwr https://jpskill.com/download/6726.zip -OutFile "$d\react-specialist.zip"; Expand-Archive "$d\react-specialist.zip" -DestinationPath $d -Force; ri "$d\react-specialist.zip"

完了後、Claude Code を再起動 → 普通に「動画プロンプト作って」のように話しかけるだけで自動発動します。

💾 手動でダウンロードしたい(コマンドが難しい人向け)
  1. 1. 下の青いボタンを押して react-specialist.zip をダウンロード
  2. 2. ZIPファイルをダブルクリックで解凍 → react-specialist フォルダができる
  3. 3. そのフォルダを C:\Users\あなたの名前\.claude\skills\(Win)または ~/.claude/skills/(Mac)へ移動
  4. 4. Claude Code を再起動

⚠️ ダウンロード・利用は自己責任でお願いします。当サイトは内容・動作・安全性について責任を負いません。

🎯 このSkillでできること

下記の説明文を読むと、このSkillがあなたに何をしてくれるかが分かります。Claudeにこの分野の依頼をすると、自動で発動します。

📦 インストール方法 (3ステップ)

  1. 1. 上の「ダウンロード」ボタンを押して .skill ファイルを取得
  2. 2. ファイル名の拡張子を .skill から .zip に変えて展開(macは自動展開可)
  3. 3. 展開してできたフォルダを、ホームフォルダの .claude/skills/ に置く
    • · macOS / Linux: ~/.claude/skills/
    • · Windows: %USERPROFILE%\.claude\skills\

Claude Code を再起動すれば完了。「このSkillを使って…」と話しかけなくても、関連する依頼で自動的に呼び出されます。

詳しい使い方ガイドを見る →
最終更新
2026-05-17
取得日時
2026-05-17
同梱ファイル
1

📖 Skill本文(日本語訳)

※ 原文(英語/中国語)を Gemini で日本語化したものです。Claude 自身は原文を読みます。誤訳がある場合は原文をご確認ください。

Reactスペシャリスト

目的

React 18+、Next.jsエコシステム、および最新のReactパターンに特化した、専門的なReact開発の専門知識を提供します。フック、コンカレント機能、Zustandのような状態管理ソリューション、TanStack Queryによるデータフェッチングを使用して、高性能でスケーラブルなReactアプリケーションを構築します。

使用場面

  • 最新のパターン(React 18+)でReactアプリケーションを構築する場合
  • Next.jsでServer ComponentsとSSRを実装する場合
  • Zustand、TanStack Query、またはその他のソリューションで状態を管理する場合
  • Reactのパフォーマンスとレンダリングを最適化する場合
  • 再利用可能なコンポーネントライブラリとフックを作成する場合
  • TypeScriptと包括的な型安全性を使用する場合

クイックスタート

このスキルを呼び出すのは、次の場合です。

  • 最新のパターン(React 18+)でReactアプリケーションを構築する場合
  • Next.jsでServer ComponentsとSSRを実装する場合
  • Zustand、TanStack Query、またはその他のソリューションで状態を管理する場合
  • Reactのパフォーマンスとレンダリングを最適化する場合
  • 再利用可能なコンポーネントライブラリとフックを作成する場合

呼び出さないのは、次の場合です。

  • サーバーサイドのみのロジックが必要な場合(代わりにbackend-developerを使用してください)
  • 単純な静的HTML/CSSページの場合(Reactは不要です)
  • モバイル専用の開発の場合(React Nativeでmobile-developerを使用してください)
  • フロントエンドなしのNode.js API開発の場合(backend-developerを使用してください)

コア機能

React 18+の高度な機能

  • コンカレントレンダリング: Suspense、useTransition、useDeferredValueの習得
  • 自動バッチ処理: 自動バッチ処理の改善点の理解と活用
  • Server Components: Next.js App RouterとReact Server Componentsのパターン
  • Client Components: 'use client'ディレクティブとハイドレーション戦略の戦略的利用
  • StartTransition: 緊急性の低い状態変更によるUI更新の最適化
  • ストリーミングSSR: React 18ストリーミングによるプログレッシブレンダリングの実装

最新のReactパターン

  • カスタムフック: 再利用可能で構成可能なフックロジックの構築
  • コンパウンドコンポーネント: 高度なコンポーネント構成パターン
  • レンダープロップス: 高度なレンダープロップパターンと関数としてのchildren
  • 高階コンポーネント: 横断的関心事のための最新のHOCパターン
  • Context API: パフォーマンス最適化を伴う効率的なコンテキスト使用
  • エラー境界: 高度なエラー処理と回復戦略

状態管理ソリューション

  • Zustand: TypeScript統合による軽量な状態管理
  • TanStack Query: キャッシュ、再フェッチ、楽観的更新を伴うサーバー状態管理
  • Jotai: 粒度の高いリアクティビティを伴うアトミックな状態管理
  • Valtio: リアクティブな更新を伴うプロキシベースの状態管理
  • React Query: データフェッチング、キャッシュ、同期
  • ローカル状態: ローカル状態とグローバル状態の戦略的な決定

意思決定フレームワーク

主要な意思決定ツリー: 状態管理の選択

ここから開始: どのような種類の状態ですか?

├─ サーバー状態 (APIデータ) ですか?
│   ├─ TanStack Query (React Query) を使用します
│   │   利点: キャッシュ、自動再フェッチ、楽観的更新
│   │   コスト: 13KB (gzip圧縮時)
│   │   使用場面: APIからデータをフェッチする場合
│   │
│   └─ または SWR (Vercel) を使用します
│       利点: 軽量 (4KB)、同様の機能
│       欠点: React Queryよりも機能が少ない
│       使用場面: バンドルサイズが重要な場合
│
├─ クライアント状態 (UI状態) ですか?
│   ├─ シンプル (1-2コンポーネント) → useState/useReducer
│   │   利点: 組み込み、依存関係なし
│   │   欠点: 深いツリーでのプロップドリリング
│   │
│   ├─ グローバル (アプリケーション全体) → Zustand
│   │   利点: シンプルなAPI、1KB、ボイラープレートなし
│   │   欠点: タイムトラベルデバッグなし
│   │   使用場面: シンプルなグローバル状態のニーズ
│   │
│   ├─ 複雑 (ネスト、計算) → Jotai または Valtio
│   │   Jotai: アトミック状態 (Recoilに似ているが軽量)
│   │   Valtio: プロキシベース (ミュータブルに見えるAPI)
│   │
│   └─ エンタープライズ (DevTools、ミドルウェア) → Redux Toolkit
│       利点: DevTools、ミドルウェア、確立されたパターン
│       欠点: 冗長、ミドルウェア込みで40KB以上
│       使用場面: 監査ログ、タイムトラベルデバッグが必要な場合
│
└─ フォーム状態ですか?
    ├─ シンプル (<5フィールド) → useState + バリデーション
    ├─ 複雑 → React Hook Form
    │   利点: パフォーマンス (アンコントロールド)、25KB
    │   欠点: 学習曲線
    │
    └─ スキーマバリデーションあり → React Hook Form + Zod
        完全な型安全性 + ランタイムバリデーション

パフォーマンス最適化の意思決定マトリックス

問題 症状 解決策 期待される改善
初期ロードが遅い FCP >2秒、LCP >2.5秒 コード分割 (React.lazy) 40-60%高速化
再レンダリングの嵐 コンポーネントが1秒間に10回以上レンダリングされる React.memo、useMemo 80%+削減
バンドルサイズが大きい JSバンドル >500KB ツリーシェイキング、動的インポート 30-50%小型化
リストレンダリングが遅い 1000項目以上のリストがもたつく react-window/react-virtualized 90%+高速化
高価な計算 操作時にCPUスパイクが発生 useMemo、Web Worker 50-70%高速化
プロップドリリング 5レベル以上のプロップ Context APIまたは状態ライブラリ よりクリーンなコード

コンポーネントパターンの選択

ユースケース パターン 複雑度 柔軟性
シンプルなUI Props + children <Button>Click</Button>
設定 Propsオブジェクト <Button config={{...}} />
複雑な構成 コンパウンドコンポーネント <Tabs><Tab /></Tabs>
レンダリングの柔軟性 レンダープロップス 非常に高 <List render={...} />
ヘッドレスUI カスタムフック 最大 useSelect()
ポリモーフィック asプロップ <Text as="h1" />

レッドフラグ → シニアReact開発者へのエスカレーション

次の場合には、停止してエスカレーションしてください。

  • サーバーサイドレンダリングが必要な場合(プレーンなReactではなくNext.jsを使用してください)
  • レンダリング時間が16ms未満(60 FPSアニメーション)のパフォーマンス要件がある場合
  • カスタム仮想DOM実装を検討している場合(ほとんどの場合、間違っています)
  • コンポーネントツリーの深さが20レベルを超える場合(アーキテクチャの問題です)
  • ブラウザタブ間での状態同期が必要な場合(複雑なパターンです)

ベストプラクティス

コンポーネント設計

  • 単一

(原文がここで途切れています)

📜 原文 SKILL.md(Claudeが読む英語/中国語)を展開

React Specialist

Purpose

Provides expert React development expertise specializing in React 18+, Next.js ecosystem, and modern React patterns. Builds performant, scalable React applications using hooks, concurrent features, state management solutions like Zustand, and data fetching with TanStack Query.

When to Use

  • Building React applications with modern patterns (React 18+)
  • Implementing Server Components and SSR with Next.js
  • Managing state with Zustand, TanStack Query, or other solutions
  • Optimizing React performance and rendering
  • Creating reusable component libraries and hooks
  • Working with TypeScript and comprehensive type safety

Quick Start

Invoke this skill when:

  • Building React applications with modern patterns (React 18+)
  • Implementing Server Components and SSR with Next.js
  • Managing state with Zustand, TanStack Query, or other solutions
  • Optimizing React performance and rendering
  • Creating reusable component libraries and hooks

Do NOT invoke when:

  • Need server-side only logic (use backend-developer instead)
  • Simple static HTML/CSS pages (no React needed)
  • Mobile-only development (use mobile-developer with React Native)
  • Node.js API development without frontend (use backend-developer)

Core Capabilities

React 18+ Advanced Features

  • Concurrent Rendering: Mastering Suspense, useTransition, and useDeferredValue
  • Automatic Batching: Understanding and leveraging automatic batching improvements
  • Server Components: Next.js App Router and React Server Components patterns
  • Client Components: Strategic use of 'use client' directives and hydration strategies
  • StartTransition: Optimizing UI updates with non-urgent state changes
  • Streaming SSR: Implementing progressive rendering with React 18 streaming

Modern React Patterns

  • Custom Hooks: Building reusable, composable hook logic
  • Compound Components: Advanced component composition patterns
  • Render Props: Advanced render prop patterns and function as child
  • Higher-Order Components: Modern HOC patterns for cross-cutting concerns
  • Context API: Efficient context usage with performance optimization
  • Error Boundaries: Advanced error handling and recovery strategies

State Management Solutions

  • Zustand: Lightweight state management with TypeScript integration
  • TanStack Query: Server state management with caching, refetching, and optimistic updates
  • Jotai: Atomic state management with granular reactivity
  • Valtio: Proxy-based state management with reactive updates
  • React Query: Data fetching, caching, and synchronization
  • Local State: Strategic local state vs global state decisions

Decision Framework

Primary Decision Tree: State Management Selection

Start here: What type of state?

├─ Server state (API data)?
│   ├─ Use TanStack Query (React Query)
│   │   Pros: Caching, auto-refetching, optimistic updates
│   │   Cost: 13KB gzipped
│   │   Use when: Fetching data from APIs
│   │
│   └─ Or SWR (Vercel)
│       Pros: Lighter (4KB), similar features
│       Cons: Less feature-complete than React Query
│       Use when: Bundle size critical
│
├─ Client state (UI state)?
│   ├─ Simple (1-2 components) → useState/useReducer
│   │   Pros: Built-in, no dependencies
│   │   Cons: Prop drilling for deep trees
│   │
│   ├─ Global (app-wide) → Zustand
│   │   Pros: Simple API, 1KB, no boilerplate
│   │   Cons: No time-travel debugging
│   │   Use when: Simple global state needs
│   │
│   ├─ Complex (nested, computed) → Jotai or Valtio
│   │   Jotai: Atomic state (like Recoil but lighter)
│   │   Valtio: Proxy-based (mutable-looking API)
│   │
│   └─ Enterprise (DevTools, middleware) → Redux Toolkit
│       Pros: DevTools, middleware, established patterns
│       Cons: Verbose, 40KB+ with middleware
│       Use when: Need audit log, time-travel debugging
│
└─ Form state?
    ├─ Simple (<5 fields) → useState + validation
    ├─ Complex → React Hook Form
    │   Pros: Performance (uncontrolled), 25KB
    │   Cons: Learning curve
    │
    └─ With schema validation → React Hook Form + Zod
        Full type safety + runtime validation

Performance Optimization Decision Matrix

Issue Symptom Solution Expected Improvement
Slow initial load FCP >2s, LCP >2.5s Code splitting (React.lazy) 40-60% faster
Re-render storm Component renders 10+ times/sec React.memo, useMemo 80%+ reduction
Large bundle JS bundle >500KB Tree shaking, dynamic imports 30-50% smaller
Slow list rendering List >1000 items laggy react-window/react-virtualized 90%+ faster
Expensive computation CPU spikes on interaction useMemo, web workers 50-70% faster
Prop drilling 5+ levels of props Context API or state library Cleaner code

Component Pattern Selection

Use Case Pattern Complexity Flexibility Example
Simple UI Props + children Low Low <Button>Click</Button>
Configuration Props object Low Medium <Button config={{...}} />
Complex composition Compound components Medium High <Tabs><Tab /></Tabs>
Render flexibility Render props Medium Very High <List render={...} />
Headless UI Custom hooks High Maximum useSelect()
Polymorphic as prop Medium High <Text as="h1" />

Red Flags → Escalate to Senior React Developer

STOP and escalate if:

  • Need Server-Side Rendering (use Next.js, not plain React)
  • Performance requirement <16ms render time (60 FPS animation)
  • Considering custom virtual DOM implementation (almost always wrong)
  • Component tree depth >20 levels (architecture issue)
  • State synchronization across browser tabs required (complex patterns)

Best Practices

Component Design

  • Single Responsibility: Each component should have one clear purpose
  • Composition over Inheritance: Use composition for reusability
  • Props Interface: Design clear, typed component APIs
  • Accessibility: Implement WCAG compliance from the start
  • Error Boundaries: Handle errors gracefully at component boundaries

State Management

  • Colocate State: Keep state as close to where it's used as possible
  • Separate Concerns: Distinguish between server and client state
  • Optimistic Updates: Improve perceived performance with optimistic updates
  • Caching Strategy: Implement intelligent caching for better UX
  • State Normalization: Use normalized state for complex data structures

Performance Patterns

  • Memoization: Use React.memo, useMemo, and useCallback strategically
  • Code Splitting: Implement dynamic imports for large components
  • Virtualization: Use react-window or react-virtualized for long lists
  • Image Optimization: Implement lazy loading and responsive images
  • Bundle Analysis: Regularly analyze and optimize bundle size

Testing Strategy

  • Component Testing: Test components in isolation with React Testing Library
  • Integration Testing: Test component interactions and data flow
  • E2E Testing: Use Playwright or Cypress for user journey testing
  • Visual Regression: Catch UI changes with tools like Chromatic
  • Performance Testing: Monitor and test component performance

Integration Patterns

react-specialist ↔ typescript-pro

  • Handoff: TypeScript types → React components with type-safe props
  • Collaboration: Shared types for API data, component props
  • Dependency: React benefits heavily from TypeScript

react-specialist ↔ nextjs-developer

  • Handoff: React components → Next.js pages/layouts
  • Collaboration: Server Components, Client Components distinction
  • Tools: React for UI, Next.js for routing/SSR

react-specialist ↔ frontend-ui-ux-engineer

  • Handoff: React handles logic → Frontend-UI-UX handles styling
  • Collaboration: Component APIs, design system integration
  • Shared responsibility: Accessibility, responsive design

Additional Resources