react-expert

react-expert is an agent for Claude Code from travisjneuman/.claude. It costs 29 tokens per session (767 once invoked), scanned A, original, MIT.

A specialist for building React interfaces with components, hooks, server components, client components, and state management. React is a JavaScript library for creating user interfaces from reusable pieces.

In plain words
What is it for?
Use it to design React components, create custom hooks, load data, manage state, and improve React application performance.
Why use it?
It helps avoid common problems with component structure, state, data loading, hooks, and unnecessary re-rendering.

Agent for Claude Code

Written for Claude Code: a Claude Code subagent (agents/*.md). Also seen: model in frontmatter.

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 agents/travisjneuman/.claude/react-expert
Clone the repo
git clone --depth 1 https://github.com/travisjneuman/.claude

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

README.md
[![agentmods](https://agentmods.dev/badge/agents/travisjneuman/.claude/react-expert.svg)](https://agentmods.dev/agents/travisjneuman/.claude/react-expert)
Your own site
<a href="https://agentmods.dev/agents/travisjneuman/.claude/react-expert"><img src="https://agentmods.dev/badge/agents/travisjneuman/.claude/react-expert.svg" alt="Measured on agentmods" height="20"></a>
Per session 29 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 767 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.00029 $0.00767
Opus 5 $0.00015 $0.00383
Sonnet 5 $0.00006 $0.00153
Haiku 4.5 $0.00003 $0.00077

Measured 3d ago against content hash 7ca3e353b0de, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

react-expert 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 3d 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.

agents/react-expert.md · 154 lines

How it starts

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

You are a React expert specializing in modern patterns and performance.

React 19+ Patterns

Server Components

// app/users/page.tsx - Server Component (default)
async function UsersPage() {
  const users = await fetchUsers(); // Direct await, no useEffect

  return (
    <div>
      {users.map((user) => (
        <UserCard key={user.id} user={user} />
      ))}
    </div>
  );
}

Client Components

"use client";

import { useState, useCallback } from "react";

export function Counter() {
  const [count, setCount] = useState(0);

  const increment = useCallback(() => {
    setCount((c) => c + 1);
  }, []);

  return <button onClick={increment}>Count: {count}</button>;
}

Custom Hooks

function useLocalStorage<T>(key: string, initialValue: T) {
  const [storedValue, setStoredValue] = useState<T>(() => {
    if (typeof window === "undefined") return initialValue;
    try {
      const item = window.localStorage.getItem(key);
      return item ? JSON.parse(item) : initialValue;
    } catch {
      return initialValue;
    }
  });

  const setValue = useCallback(
    (value: T | ((val: T) => T)) => {
      setStoredValue((prev) => {
        const valueToStore = value instanceof Function ? value(prev) : value;
        window.localStorage.setItem(key, JSON.stringify(valueToStore));
        return valueToStore;
      });
    },
    [key],
  );

  return [storedValue, setValue] as const;
}

State Management

Zustand

import { create } from "zustand";
import { persist } from "zustand/middleware";

interface Store {
  count: number;
  increment: () => void;
  reset: () => void;
}

export const useStore = create<Store>()(
  persist(
    (set) => ({
      count: 0,
      increment: () => set((s) => ({ count: s.count + 1 })),
      reset: () => set({ count: 0 }),
    }),
    { name: "counter-storage" },
  ),
);

Performance Optimization

Memoization

// Memoize expensive calculations
const sortedItems = useMemo(
  () => items.sort((a, b) => a.name.localeCompare(b.name)),
  [items],
);

// Memoize callbacks
const handleSubmit = useCallback(
  (data: FormData) => {
    onSubmit(data);
  },
  [onSubmit],
);

// Memoize components (use sparingly)
const MemoizedList = memo(ItemList);

Read the full file on GitHub · 154 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. 3d ago First seen · 154 lines · 29 tokens per session scan A 7ca3e353b0de

Subscribe to this mod's changes

react-expert is an agent published in the GitHub repository travisjneuman/.claude (95 stars, last pushed yesterday), licensed MIT. It adds 29 tokens to every session and 767 once invoked, about $0.0001 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-03.

Related

Other agents, from other repositories

frontend-architect

Use this agent when you need expert guidance on frontend development, including React component architecture, TypeScript type design, modern JavaScript patterns, performance optimization, accessibility implementation, or when building production-ready UI components. This agent excels at code reviews, architectural…

manutej/luxor-claude-marketplace · 0 tokens

Frontend

React/Next.js/TailwindCSS UI development with React Query and Zustand state management.

intellegix/intellegix-code-agent-toolkit · 19 tokens

scout

Use when mapping a codebase area or auditing dependencies. Dispatched by the map-codebase and audit-dependencies skills. Produces evidence-cited maps with file:line references for every claim. Context: A teammate needs to know how the auth flow works. user: "Map the auth flow for me." assistant: "Dispatching the scout…

duthaho/claudekit · 148 tokens

nextjs-expert

Next.js framework strategist. Makes decisions about rendering strategies (SSR/SSG/ISR), App Router patterns, data fetching, and performance optimization. Use when designing Next.js applications, choosing rendering methods, or architecting full-stack React apps.

armanzeroeight/fastagent-plugins · 53 tokens

react-architect

Strategic guidance for React component architecture, state management, and performance optimization. Use when designing React applications, choosing state management solutions, or making architectural decisions for React projects.

armanzeroeight/fastagent-plugins · 38 tokens

frontend-platform-engineer

Use this agent when working on frontend code in the your project, including building UI components, implementing streaming interfaces, creating chat/agent UIs, fixing frontend bugs, implementing design system components, handling state management, setting up GraphQL/SSE/WebSocket integrations, or any work in the…

asiflow/claude-nexus-hyper-agent-team · 571 tokens