react-compositional
Installation
SKILL.md
React Compositional Components
Build functional, compositional React components following headless UI patterns with proper state separation and react-query integration.
Core Workflow
When creating compositional components:
- Identify state types - Separate UI state from server state
- Extract logic to hooks - Create headless hooks for reusable logic
- Design composition API - Plan how components combine (compound, slots, render props)
- Implement pure components - Ensure idempotency and no side effects in render
- Integrate react-query - Add server state management where needed
- Support both patterns - Allow controlled and uncontrolled usage