extract

Extract reusable components, design tokens, and patterns into a design system.

Updated Mar 15, 2026
One-click install
npx skills add https://github.com/WeWake1/BSOMS --skill extract-wewake1
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: extract
Source: https://github.com/WeWake1/BSOMS/tree/main/.agents/skills/extract
Command: npx skills add https://github.com/WeWake1/BSOMS --skill extract-wewake1

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Codebases accumulate duplicated UI patterns, hard-coded style values, and inconsistent component variations that increase maintenance cost and visual inconsistency. This Skill identifies those repeated patterns and consolidates them into a shared design system. ## Core Features & Use Cases - Pattern Discovery: Scans a target area to find repeated components, hard-coded colors, spacing, and typography values, and inconsistent implementations of the same concept. - Component & Token Extraction: Builds reusable components with typed props, variants, and accessibility support, plus semantically named design tokens. - Migration & Documentation: Replaces existing usages with shared versions, removes dead code, and updates component library documentation. - Use Case: A team notices three different button styles across their Next.js app. Use this Skill to consolidate them into one typed Button component with variants, migrate all call sites, and document it in the component library. ## Quick Start Ask the AI to extract reusable components and design tokens from a specific feature or directory in your project.

Frequently Asked Questions about extract

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract reusable components from an existing codebase?▼

Scan the target area for UI patterns used three or more times, then create a shared component with a clear props API, variants, and accessibility support. Finally, migrate all existing usages to the shared version and delete the old implementations.

When should hard-coded values become design tokens?▼

Convert colors, spacing, typography, and shadows into tokens when they repeat across components and carry semantic meaning. Avoid creating tokens for every single value, since tokens should represent reusable design decisions rather than one-off constants.

What if my project has no design system yet?▼

The Skill instructs the AI to ask before creating one, confirming the preferred location and structure first. It will not invent a design system directory without understanding your project's conventions.

Which patterns should not be extracted into a design system?▼

Avoid extracting one-off, context-specific implementations or components so generic they become useless. Only systematize patterns used multiple times where the consistency benefit outweighs the maintenance cost.

Does component extraction include accessibility support?▼

Yes. Extracted components are built with ARIA attributes, keyboard navigation, and focus management, along with proper TypeScript types and prop documentation.