Implements proven refactoring patterns to systematically improve code structure and readability while preserving observable behavior.
The Refactoring Catalog skill provides a structured framework for identifying and applying low-risk code transformations based on industry standards from Martin Fowler and Michael Feathers. It guides developers through the process of eliminating code smells—such as duplication, long methods, and complex conditionals—by breaking down improvements into tiny, verifiable steps. By emphasizing a safety-first approach with test-driven validation, this skill helps reduce technical debt and cognitive load without risking functional regressions.
Key Features
01Systematically replaces magic numbers with intention-revealing constants
02Guides the application of patterns like Extract Method and Move Method
03Transforms complex nested conditionals into clean polymorphic logic
04Identifies common code smells including duplication and high coupling
055 GitHub stars
06Enforces a Red-Green-Refactor safety cycle with test validation
Use Cases
01Cleaning up complex logic after a feature implementation as part of the TDD cycle
02Preparing a legacy codebase for architectural changes by improving existing structure first
03Standardizing naming conventions and reducing method complexity during code reviews