Agent skill
scaffolding-components
Scaffold new React components with proper file structure, CSS modules, audio integration, and Storybook stories. Use when creating new components, scaffolding UI, or when user says "create component", "new component", "scaffold", "generate component", or "add component".
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/data/scaffolding-components
SKILL.md
Component Scaffolding
Generate properly structured React components following project conventions.
Workflow
Copy and track progress:
- [ ] Step 1: Create component directory
- [ ] Step 2: Create main component file (.tsx)
- [ ] Step 3: Create CSS module (.module.css)
- [ ] Step 4: Create barrel export (index.ts)
- [ ] Step 5: Create Storybook story (.stories.tsx) - if major component
- [ ] Step 6: Verify audio integration
- [ ] Step 7: Add responsive styles
Directory Structure
src/components/ComponentName/
├── ComponentName.tsx # Main component
├── ComponentName.module.css # Scoped styles
├── ComponentName.stories.tsx # Storybook (optional)
└── index.ts # Barrel export
Component Template
See TEMPLATES.md for ready-to-use templates.
Quick Generation
For a component named FeatureCard:
- Create directory:
src/components/FeatureCard/ - Use template: Copy from TEMPLATES.md, replace
ComponentNamewithFeatureCard - Add audio: Import
useAudioManager, add to all interactions - Add responsive: Include 768px media query
- Create story: If user-facing, create Storybook story
Audio Integration Checklist
Every interactive element needs audio:
| Interaction | Sound Type |
|---|---|
| Button click | click |
| Card hover | hover |
| Navigation | navigation |
| Back action | back |
| Panel open | panel |
| Success | achievement |
File Naming Rules
- Component:
PascalCase.tsx - CSS Module:
PascalCase.module.css - Story:
PascalCase.stories.tsx - Index:
index.ts(lowercase)
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?