smithery/valec3

frontend-state-strategy

Standardized guidelines and patterns for Frontend State Strategy.

Installation

$ npx skills add smithery/valec3 --skill frontend-state-strategy

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from smithery/valec3 · top by installs.

npx skills add smithery/valec3

Browse all from smithery/valec3

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 1,193 B
  • docs SUMMARY.md 96 B

History

  1. First recorded snapshot · 0 installs

SKILL.md

Frontend State Strategy

When to use this skill

  • Choosing state management solution
  • Architecting state in applications
  • Refactoring state management

Workflow

  • Identify state types (local, global, server)
  • Choose appropriate tool for each type
  • Avoid prop drilling
  • Colocate state with usage
  • Keep state minimal

Instructions

State Types

  1. Local State: useState, useReducer
  2. Global State: Context, Zustand, Redux
  3. Server State: React Query, SWR
  4. URL State: useSearchParams, router

Decision Tree

Is it server data? → React Query
Is it global UI state? → Zustand/Context
Is it local to component? → useState
Is it derived? → useMemo

Example

// Local
const [count, setCount] = useState(0);

// Global
const theme = useThemeStore(state => state.theme);

// Server
const { data: user } = useQuery('user', fetchUser);

// URL
const [searchParams] = useSearchParams();

Resources

  • Prefer local state
  • Server state separate from client state
  • Use Context sparingly