react-native-state-management
FreeNo executable scriptsNot checkedImplement local and global state with Context, Zustand, and Redux Toolkit in React Native. Use when choosing or implementing state management in React Native…
by HoangNguyen0403★ 598 GitHub starsAbout this skill
React Native State Management
Priority: P1 (HIGH)
State Strategy
- Local State: Use
useStatefor component-scoped state (forms, UI toggles). - Lifted State: Share between siblings via parent component.
- Context: Share across components without prop drilling (theme, auth).
- Zustand: Lightweight global state for small-medium apps.
- Redux Toolkit: Complex apps with time-travel debugging needs.
- Server State: Use
@tanstack/react-queryfor API data (caching, refetching).
const ThemeContext = createContext<ThemeContextType | undefined>(undefined);
export function useTheme() {
const ctx = useContext(ThemeContext);
if (!ctx) throw new Error('useTheme must be inside ThemeProvider');
return ctx;
}
Zustand (Recommended for Most Apps)
import { create } from 'zustand';
const useStore = create((set) => ({
count: 0,
increment: () => set((state) => ({ count: state.count + 1 })),
}));
// Usage
const count = useStore((state) => state.count);
Anti-Patterns
- No Redux for Everything: Start with Context/Zustand.
- No Prop Drilling: Use Context for global state.
- No Derived State in State: Compute in render.
References
See references/REFERENCE.md for Context patterns, Zustand store setup, Redux Toolkit, and React Query.
Install react-native-state-management in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
Bundled files
FAQ
What does the react-native-state-management skill do?
Implement local and global state with Context, Zustand, and Redux Toolkit in React Native. Use when choosing or implementing state management in React Native with Context, Zustand, or Redux.
How do I install the react-native-state-management skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the react-native-state-management skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
by Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
by Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropic