Skip to content
Back to skills

Component Design

ASecurity

Design React/Vue components following atomic design and composition

  • 27 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added February 7, 2026
developmentreactvuenodeapi

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 5 files and shows the line behind each finding

Scanned February 12, 2026

npx -y skills add vneseyoungster/ChocoVine --skill component-design --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Component Design?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Component Design
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vneseyoungster-component-design/badge)](https://www.skillsdirectory.com/skills/vneseyoungster-component-design)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: component-design
description: Design React/Vue components following atomic design and composition
  patterns. Use when creating UI components.
---

# Component Design Skill

## Purpose
Create consistent, reusable UI components.

## Atomic Design
Reference: [patterns/atomic-design.md](patterns/atomic-design.md)

### Hierarchy
1. **Atoms**: Basic elements (Button, Input, Label)
2. **Molecules**: Simple groups (FormField, SearchBox)
3. **Organisms**: Complex sections (Header, Form, Card)
4. **Templates**: Page layouts
5. **Pages**: Specific instances

## Component Patterns
Reference: [patterns/composition.md](patterns/composition.md)

### Compound Components
```tsx
<Select>
  <Select.Trigger />
  <Select.Content>
    <Select.Item value="1">Option 1</Select.Item>
  </Select.Content>
</Select>
```

### Render Props
```tsx
<DataFetcher url="/api/users">
  {({ data, loading }) => (
    loading ? <Spinner /> : <UserList users={data} />
  )}
</DataFetcher>
```

### Custom Hooks
```tsx
function useUser(id: string) {
  const [user, setUser] = useState(null);
  const [loading, setLoading] = useState(true);
  // ...
  return { user, loading, error };
}
```

## Props Interface
```tsx
interface ButtonProps {
  /** Visual variant of the button */
  variant?: 'primary' | 'secondary' | 'ghost';
  /** Size of the button */
  size?: 'sm' | 'md' | 'lg';
  /** Whether button is disabled */
  disabled?: boolean;
  /** Click handler */
  onClick?: () => void;
  /** Button content */
  children: React.ReactNode;
}
```

## Component Template
Use: [templates/component-template.tsx](templates/component-template.tsx)

## State Management
Reference: [patterns/state-management.md](patterns/state-management.md)

### Decision Tree
1. UI-only state → `useState`
2. Complex local state → `useReducer`
3. Shared between siblings → Lift to parent
4. Shared across app → Context or global store
5. Server state → React Query/SWR

Files in this skill

  • SKILL.md1.9 KB
  • patterns/atomic-design.md4.6 KB
  • patterns/composition.md5.3 KB
  • patterns/state-management.md5.1 KB
  • templates/component-template.tsx5.7 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…