What problem does it solve?
This Skill addresses the challenge of maintaining and improving existing codebases by making structural enhancements without altering the code's external behavior, leading to more readable, maintainable, and robust software.
Core Features & Use Cases
- Code Simplification: Reduces complexity by splitting long functions, improving naming, and removing dead code.
- Duplication Consolidation: Identifies and merges redundant code blocks into single, reusable implementations.
- Behavior Preservation: Ensures that all changes are behavior-preserving, verified through automated checks or careful inspection.
- Use Case: When a function becomes too long and difficult to understand, use this Skill to extract parts of it into smaller, well-named functions, making the overall logic clearer and easier to test.
Quick Start
Use the refactor skill to extract a long function into smaller units.