From role-frontend
Guides frontend state management in React: local/global decisions, Zustand/Redux Toolkit/Jotai/MobX/Context, TanStack Query/SWR for server state, optimistic updates, XState machines. Use for store setup, migrations, re-render fixes.
How this skill is triggered — by the user, by Claude, or both
Slash command
/role-frontend:state-managementThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
- Deciding where state lives — local, global, server cache, URL, or form
nuqs or router search paramsreferences/react-state-primitives.md — state category decision table, useState/useReducer patterns, useContext (when/when not), useSyncExternalStore, React 19 use(), stale closure preventionreferences/server-state-tanstack-query.md — TanStack Query v5 queries, optimistic mutations with onMutate/onError/onSettled, infinite queries, prefetch on hover, SWR alternativereferences/global-state-zustand-jotai-redux.md — Zustand with immer/persist/devtools middleware, granular selectors, Jotai atom composition, RTK createSlice/createEntityAdapter, URL state with nuqs, React Hook Form + Zod, XState machines, Preact signals, anti-patternsnpx claudepluginhub rnavarych/alpha-engineer --plugin role-frontendGuides React state management decisions: useState/useReducer, Context, Zustand, Jotai, Redux Toolkit, TanStack Query, SWR. Detects installed libraries and applies matching patterns.
Guides modern React state management with Redux Toolkit, Zustand, Jotai, and React Query. Use for global state setup, server state, or choosing solutions.
Guides on frontend state management: Redux, Zustand, MobX, Jotai, Recoil, React Context. Helps choose the right solution, implement store architecture, and fix issues like prop drilling or stale state.