component-flattening-a…
Detects misplaced classes and fixes component hierarchy problems — finds code that should belong inside a component but sits at the root level. Use when asking…
Finds duplicate business logic spread across multiple components and suggests consolidation. Use when asking "where is this logic duplicated?", "find common code between services", "what can be consolidated?", "detect shared domain logic", or analyzing component overlap before
$ npx -y skills add tech-leads-club/agent-skills --skill component-common-domain-detection --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/component-common-domain-detectionContext preview
The summary Claude sees to decide when to auto-load this skill.
Finds duplicate business logic spread across multiple components and suggests consolidation. Use when asking "where is this logic duplicated?", "find common code between services", "what can be consolidated?", "detect shared domain logic", or analyzing component overlap before
name: component-common-domain-detection description: Finds duplicate business logic spread across multiple components and suggests consolidation. Use when asking "where is this logic duplicated?", "find common code between services", "what can be consolidated?", "detect shared domain logic", or analyzing component overlap before refactoring. Do NOT use for code-level duplication detection (use linters) or dependency analysis (use coupling-analysis).
This skill identifies common domain functionality that is duplicated across multiple components and suggests consolidation opportunities to reduce duplication and improve maintainability.
Request analysis of your codebase:
**Example 1: Find Common Functionality**
User: "Find common domain functionality across components" The skill will: 1. Scan component namespaces for common patterns 2. Detect shared classes used across components 3. Identify duplicate domain logic 4. Analyze coupling impact of consolidation 5. Suggest consolidation opportunities
**Example 2: Detect Duplicate Notification Logic**
User: "Are there multiple notification components that should be consolidated?" The skill will: 1. Find all components with notification-related names 2. Analyze their functionality and dependencies 3. Calculate coupling impact if consolidated 4. Recommend consolidation approach
**Example 3: Analyze Shared Classes**
User: "Find classes that are shared across multiple components" The skill will: 1. Identify classes imported/used by multiple components 2. Classify as domain vs infrastructure functionality 3. Suggest consolidation or shared library approach 4. Assess impact on coupling
1. **Scan Components**: Identify components with common namespace patterns 2. **Detect Shared Code**: Find classes/files used across components 3. **Analyze Functionality**: Determine if functionality is truly common 4. **Assess Coupling**: Calculate coupling impact before consolidation 5. **Recommend Actions**: Suggest consolidation or shared library approach
Apply this skill when:
**Domain Functionality** (candidates for consolidation):
**Infrastructure Functionality** (usually not consolidated here):
Common domain functionality often appears as:
1. **Namespace Patterns**: Components ending in same leaf node
2. **Shared Classes**: Same class used across multiple components
3. **Similar Functionality**: Different components doing similar things
**Shared Service**:
**Shared Library**:
**Component Consolidation**:
Scan component namespaces for common leaf node names:
1. **Extract leaf nodes** from all component namespaces
2. **Group by common leaf nodes**
3. **Filter out infrastructure patterns**
**Example Output**:
## Common Namespace Patterns Found **Notification Components**: - services/customer/notification - services/ticket/notification - services/survey/notification **Audit Components**: - services/billing/audit - services/ticket/audit - services/survey/audit
Find classes/files used across multiple components:
1. **Scan imports/dependencies** in each component
2. **Identify shared classes**
3. **Classify as domain vs infrastructure**
**Example Output**:
## Shared Classes Found **Domain Classes**: - `SMTP
The secure, validated skill registry for professional AI coding agents. Extend Antigravity, Claude Code, Cursor, Copilot and more with absolute confidence.
Repo: tech-leads-club/agent-skills
Detects misplaced classes and fixes component hierarchy problems — finds code that should belong inside a component but sits at the root level. Use when asking…
Maps architectural components in a codebase and measures their size to identify what should be extracted first. Use when asking "how big is each module?",…
Analyzes coupling between modules using the three-dimensional model (strength, distance, volatility) from "Balancing Coupling in Software Design". Use when…
Creates step-by-step decomposition plans and migration roadmaps for breaking apart monolithic applications. Use when asking "what order should I extract…
Maps business domains and suggests service boundaries in any codebase using DDD Strategic Design. Use when asking "what are the domains in this codebase?",…
Groups existing components into logical business domains to plan service-based architecture. Use when asking "which components belong together?", "group these…