Add a New Feature

Learn how to safely add complex features to an existing codebase using the /enhance workflow.

Overview

The /enhance workflow is your day-to-day tool for iterative development. Unlike /create which builds from scratch, /enhance focuses on surgically adding functionality without breaking existing code.

Scenario: Adding a "Dashboard Analytics" feature to an existing SaaS application.

The Process

1

Feature Planning

Describe your feature requirements clearly.

/enhance Add an analytics dashboard for user activity
Requirements:
- Track daily active users and page views
- Visual charts using Recharts
- API endpoint to aggregate data
2

Component Implementation

Specialists implement the full vertical slice.

Database
Backend
Frontend
Testing
3

Verify Integration

Run final checks to validate bundle size, accessibility, and tests.

Example Session

User: /enhance add dark mode toggle
Agent: Analyzing codebase...

Found: Tailwind CSS with no dark mode config
Plan: Update tailwind.config, add ThemeProvider, create toggle component

Frontend: Creating ThemeToggle...
Testing: Adding theme tests...
Agent: ✅ Feature Added!
Run /preview start to test.

Pro Tips

Check Dependencies

Use checklist.py to prevent bundle bloat from new libraries.

Keep It Modular

Isolate new components to minimize side effects on existing code.

Next Steps