--- name: component-patterns description: "React/Next.js component design pattern library. Provides Compound/Render Props/HOC/Custom Hooks patterns, state management strategies (Zustand/React Query/Context), and folder structure conventions as a frontend-dev extension skill. Use for requests like 'component patterns', 'React patterns', 'state management', 'folder structure', 'Custom Hook', 'component separation', and other frontend architecture design tasks. However, actual code implementation or backend logic is outside this skill's scope." --- # Component Patterns — React/Next.js Component Design Patterns A reference for component patterns, state management strategies, and project structure that the frontend-dev agent uses during frontend development. ## Target Agent `frontend-dev` — Applies this skill's patterns directly to component design and state management. ## Component Design Patterns ### 1. Compound Components A pattern where parent and child share implicit state. **Suited for**: Tab, Accordion, Dropdown, Select, and other composite UI **Structure**: `