Migration Philosophy
The Conty Design System migration follows these core principles:- Incremental without stopping the product - migrate in waves by domain
- Feature flags and fallbacks - maintain escape hatches for critical flows
- Token-first, no hardcode - all visual values must exist in
tokens.json - Storybook as source of truth - validate components in Storybook before production
Migration Waves
Components are migrated in five progressive waves, ordered by risk and complexity.Wave 0: Inventory and Classification
Objective: Understand what exists and prioritize migration.Audit existing components
Create an inventory of all UI components in your codebase:Document:
- Component name
- Usage count (how many files import it)
- Complexity (simple/medium/complex)
- Business criticality (low/medium/high)
Classify by risk
Assign a migration priority based on:
| Factor | Weight | Description |
|---|---|---|
| Usage | High | More usage = higher priority |
| Complexity | Medium | Simpler = migrate earlier |
| Criticality | High | Critical flows need more testing |
| Stability | Low | Stable components are easier |
Wave 1: Action and Feedback Components
Timeline: Weeks 2-3 (Pilot phase) Scope: Low-risk, high-usage components for user actions and feedback. Components:ButtonBadgeAlertToast
- Simple, stable APIs
- High visibility allows quick validation
- Low risk of breaking complex interactions
- Pilot in production without critical regression
- Visual parity with legacy components
- Accessibility checks pass
- Migration pattern documented
Wave 2: Form Components
Timeline: Weeks 3-5 Scope: Input and selection components. Components:InputTextareaSelectCheckboxRadioSwitch
- Form validation must be preserved
- Error states need thorough testing
- Accessibility (ARIA labels, focus management) is critical
- Controlled and uncontrolled modes work
- Form libraries (React Hook Form, Formik) integrate properly
- Validation error display is consistent
- Keyboard navigation works as expected
- Screen reader announcements are correct
Wave 3: Navigation and Layout
Timeline: Weeks 5-7 Scope: Navigation, dialogs, and layout components. Components:TabsDialogPopoverTooltipCard(if not in Wave 1)
- Focus trapping in modals must work correctly
- Keyboard shortcuts should be preserved
- Portal rendering needs SSR compatibility
- Nested dialogs (if used)
- Tooltip positioning near viewport edges
- Tab navigation with dynamic content
Wave 4: Complex Components
Timeline: Weeks 7-10 Scope: Data-heavy and specialized components. Components:Table/DataTable- Rich text editors
- File upload components
- Payment/checkout components
- Domain-specific components
- Migrate one at a time with extensive testing
- Use feature flags for gradual rollout
- Monitor error rates and user feedback closely
- Performance testing (especially for tables with large datasets)
- Integration tests for multi-step flows
- Visual regression tests
- Cross-browser compatibility
Wave 5: Full Adoption
Timeline: Week 10+ Objective: Make Design System the default for all new development. Goals:- 80%+ of screens use Design System components
- Legacy components are deprecated (not removed)
- New features default to Design System
- Team is trained on contribution process
Rollout by Domain
Within each wave, migrate components domain by domain rather than globally.Recommended Domain Order
Authentication and Onboarding
Why first?
- Self-contained flows with clear boundaries
- High visibility for new users
- Lower complexity than core app features
- Button, Input, Card, Alert
- Login, signup, password reset, email verification, onboarding wizard
Dashboard and Main Feed
Why second?
- Most-visited area of the app
- Validates design system at scale
- Mix of simple and complex components
- Card, Badge, Button, Tabs, Tooltip
- Home dashboard, activity feed, quick actions panel
Settings and Profile
Why third?
- Form-heavy, validates Wave 2 components
- Lower traffic than dashboard (safer)
- Users expect changes in settings
- Input, Select, Switch, Button, Card
- User profile, account settings, preferences, notification settings
Billing and Payments
Why fourth?
- Critical business flow requiring extra caution
- Complex forms and validation
- High-stakes user experience
- Input, Select, Button, Dialog, Alert
- Subscription management, payment methods, invoices, billing history
Advanced Features and Admin
Why last?
- Lowest traffic, highest complexity
- Often uses specialized components
- Power users more tolerant of changes
- Table, Dialog, complex forms, custom components
- Admin panel, analytics dashboards, advanced settings, data exports
Incremental Adoption Techniques
1. Coexistence Pattern
Allow legacy and new components to coexist during migration.2. Feature Flag Pattern
Gate design system adoption behind runtime flags.- Development: Enabled for all developers
- Staging: Enabled globally
- Production: Gradual rollout (10% → 50% → 100%)
3. Module Boundary Pattern
Migrate entire modules (pages/features) at once rather than individual components.- Clear migration boundaries
- Easier to test and validate
- Simpler rollback process
4. Gradual Replacement Pattern
Replace legacy components file by file, tracking progress.Migration Testing Strategy
Pre-Migration Validation
During Migration
Incremental rollout
Deploy to production in stages:
- 5% of users for 24 hours
- 25% of users for 48 hours
- 50% of users for 72 hours
- 100% of users
Monitor key metrics
Track:
- Error rates (JavaScript errors, React errors)
- User engagement (click rates, form completions)
- Performance (Core Web Vitals)
- Accessibility violations
- User feedback and support tickets
Post-Migration
Handling Edge Cases
Custom variants not in design system
Custom variants not in design system
Problem: Your legacy component has a custom variant (e.g.,
warning badge) not in the design system.Solution:- Option A: Extend the design system component locally:
- Option B: Map to the closest design system variant:
- Option C: Propose adding the variant to the design system (preferred for reusable variants).
Breaking API changes
Breaking API changes
Problem: Design system component API differs from legacy.Solution: Create a compatibility wrapper:Use the wrapper during migration, then refactor call sites later.
Complex composed components
Complex composed components
Problem: Your component composes multiple primitives in a custom way.Solution: Rebuild using design system primitives:
Theme-specific styling
Theme-specific styling
Problem: Legacy component has hardcoded theme-specific styles.Solution: Use design tokens instead:Ensure the design token matches the intended semantic meaning.
Progress Tracking
Create a migration dashboard to track progress across waves and domains.Example Migration Dashboard
Automated Tracking
Use scripts to track import usage:Success Criteria
A migration wave is considered complete when:Functional parity
- All legacy component features are supported
- No regressions in user-facing functionality
- Forms validate and submit correctly
Visual consistency
- Visual regression tests pass
- Design team approves visual output
- Dark mode works correctly
Accessibility maintained
- No new WCAG violations
- Screen reader testing passes
- Keyboard navigation works
Performance acceptable
- No significant increase in bundle size
- Core Web Vitals remain stable
- No runtime performance regressions
Rollback Plan
Maintain the ability to rollback at each stage.Level 1: Feature Flag Rollback
Level 2: Code Rollback
Level 3: Domain Rollback
Risk Mitigation
High-Risk Areas
| Area | Risk Level | Mitigation |
|---|---|---|
| Payment/Checkout | 🔴 Critical | Feature flags + A/B test + extensive testing |
| Authentication | 🔴 Critical | Feature flags + canary deployment |
| Data editing | 🟡 High | Feature flags + user testing |
| Admin actions | 🟡 High | Testing + gradual rollout |
| Dashboard views | 🟢 Medium | Visual tests + monitoring |
| Settings pages | 🟢 Medium | Visual tests |
| Marketing pages | 🟢 Low | Visual review |
Migration Checklist per Component
Before marking a component migration as complete:- Storybook stories exist for all states
- Visual regression tests pass
- Accessibility audit shows no new violations
- TypeScript types are correct
- Dark mode works
- SSR/hydration works (for Next.js)
- Component tests pass
- Performance is acceptable
- Design team has approved
- Code review completed
- Deployed to staging and tested
- Deployed to production with feature flag
- Monitored for 48 hours minimum
- Feature flag removed (after stability confirmed)
Next Steps
conty-web Integration
See specific migration steps for conty-web
Component Reference
Explore design system component APIs
Design Tokens
Understand the token system
Contributing
Learn how to contribute new components