state-management

state-management is a skill for Claude Code from christopherlouet/claude-base. It costs 28 tokens per session (509 once invoked), scanned A, original, MIT.

Guidance for managing shared application data, including patterns and choices for tools such as Redux, Zustand, Jotai, and React features.

In plain words
What is it for?
It helps choose and structure state management for fetched data, forms, filters, drafts, authentication, themes, and other shared interface data.
Why use it?
It helps prevent mixing server data with interface state and keeps shared state separated, testable, and easier to maintain.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Good fit It helps choose and structure state management for fetched data, forms, filters…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/christopherlouet/claude-base/state-management
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.

Any agent
npx skills add christopherlouet/claude-base --skill state-management
Clone the repo
git clone --depth 1 https://github.com/christopherlouet/claude-base

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 state-management

README.md
[![agentmods](https://agentmods.dev/badge/skills/christopherlouet/claude-base/state-management.svg)](https://agentmods.dev/skills/christopherlouet/claude-base/state-management)
Your own site
<a href="https://agentmods.dev/skills/christopherlouet/claude-base/state-management"><img src="https://agentmods.dev/badge/skills/christopherlouet/claude-base/state-management.svg" alt="Measured on agentmods" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 509 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00028 $0.00509
Opus 5 $0.00014 $0.00254
Sonnet 5 $0.00006 $0.00102
Haiku 4.5 $0.00003 $0.00051

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

Security

Grade A, and why

state-management 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.

.claude/skills/state-management/SKILL.md · 48 lines

What it actually says

State Management (pointer)

Library APIs, install steps and idiomatic code drift on each release and are canonical at:

Decision tree (version-agnostic)

Need shared state?
├── No → useState/useReducer
└── Yes →
    ├── Server state (fetch + cache + invalidate) → TanStack Query / SWR
    ├── Forms → React Hook Form
    ├── Small client state (<5 stores) → Zustand
    ├── Large client state (>5 stores) → Redux Toolkit
    └── Theme/Auth singletons → Context + useReducer

Foundation discipline (keep across releases)

  • Client vs server state: never put server state in a client store (Zustand/Redux). Use TanStack Query for fetched data; Zustand/Redux for UI state, filters, drafts.
  • Domain separation: one store per domain, not one global store. Easier to test and lazy-load.
  • Granular selectors: subscribe to slices, not whole stores — see [[dev-react-perf]] for re-render audit when a store change cascades.

See also

  • dev-react-perf skill — re-render diagnosis when selectors are too broad
  • dev-tdd — store reducers/selectors test well in isolation (no DOM needed)
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 · 48 lines · 28 tokens per session scan A a7c8e6cd7432

Subscribe to this mod's changes

state-management is a skill published in the GitHub repository christopherlouet/claude-base (5 stars, last pushed yesterday), licensed MIT. It adds 28 tokens to every session and 509 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 skills, from other repositories

moai-design-tools

Design tool integration specialist covering Figma MCP, Pencil renderer, and Pencil-to-code export. Use when fetching design context from Figma, rendering Pencil designs, or exporting to React/Tailwind code.

modu-ai/moai-adk · 45 tokens

moai-ref-react-patterns

React/Next.js component design patterns, state management strategies, and project structure reference for frontend development. Agent-extending skill that amplifies frontend domain work (spawned via Agent(general-purpose) with frontend instructions) with production-grade React patterns. NOT for: backend API design…

modu-ai/moai-adk · 72 tokens

moai-domain-uiux

UI/UX design systems specialist covering accessibility, icons, theming, design tokens, and user experience patterns. Use when working on design systems, WCAG compliance, ARIA patterns, or dark mode theming.

modu-ai/moai-adk · 49 tokens

moai-domain-frontend

Frontend development specialist covering React 19, Next.js 16, Vue 3.5, and modern UI/UX patterns with component architecture. Use when building web UIs, implementing components, optimizing frontend performance, or integrating state management.

modu-ai/moai-adk · 54 tokens

generic-react-ux-designer

Professional UI/UX design expertise for React applications. Covers design thinking, user psychology (Hick's/Fitts's/Jakob's Law), visual hierarchy, interaction patterns, accessibility, performance-driven design, and design critique. Use when designing features, improving UX, solving user problems, or conducting design…

travisjneuman/.claude · 69 tokens

generic-react-feature-developer

Guide feature development for React applications with architecture focus. Covers Zustand/Redux patterns, IndexedDB usage, component systems, lazy loading strategies, and seamless integration. Use when adding new features, refactoring existing code, or planning major changes.

travisjneuman/.claude · 53 tokens