refactoring-expert

Detect and eliminate code smells in TypeScript and JavaScript projects.

Updated Aug 23, 2026
Ready to run
npx skills add https://github.com/hvngroup/directus_b2b_crm --skill refactoring-expert-hvngroup
💬 Prompt for ChatGPT / Claude Chat▼
Please help me install this Agent Skill.
Skill: refactoring-expert
Source: https://github.com/hvngroup/directus_b2b_crm/tree/main/.agent/skills/refactoring-expert
Command: npx skills add https://github.com/hvngroup/directus_b2b_crm --skill refactoring-expert-hvngroup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Systematic code improvement by identifying and addressing code smells, duplications, and overly complex structures without altering external behavior.

Core Features & Use Cases

  • Detects common code smells (long methods, duplicated code, complex conditionals)
  • Applies proven refactoring techniques (extract method, move class, replace type code)
  • Validates changes with tests and linting to ensure no behavior changes

Quick Start

Describe your project and I will begin a step-by-step, safe refactoring plan.

Frequently Asked Questions about refactoring-expert

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

FAQPage Schema
How do I identify and eliminate code smells in a TypeScript codebase?▼

To eliminate code smells in a TypeScript codebase, you detect issues like long methods, duplicated code, and complex conditionals, then apply proven refactoring techniques such as extract method. This ensures safe, incremental improvements while preserving external behavior.

What is the best way to safely refactor large methods without breaking existing behavior?▼

The best way to safely refactor large methods is applying an incremental refactoring workflow that extracts methods while validating changes with existing tests and linting to preserve external behavior.

How do I fix duplicated code and complex conditionals during object-oriented refactoring?▼

Fix duplicated code and complex conditionals during object-oriented refactoring by applying proven techniques like replace type code and move class, validating all modifications with tests to ensure no behavior changes occur.

Can I use static analysis to plan incremental refactoring for maintainability?▼

Yes, you can use static analysis to plan incremental refactoring for maintainability by identifying specific code smells and quality issues, then following a structured workflow from initial detection to final validation.

When should I avoid refactoring complex conditional logic in my project?▼

You should avoid refactoring complex conditional logic when you lack sufficient test coverage to validate behavior preservation, as safe refactoring requires tests and linting to ensure no external behavior changes occur.