refactoring
Installation
SKILL.md
Refactoring
A thorough reference covering 89 refactoring techniques and code smells — featuring PHP 8.3+ examples, rationale, step-by-step mechanics, and before/after comparisons.
Refactoring Techniques (67)
Composing Methods
- Extract Method — Pull code fragments into named methods → reference
- Inline Method — Substitute a method call with its body → reference
- Extract Variable — Give complex expressions meaningful names through explanatory variables → reference
- Inline Temp — Substitute a temporary variable with its expression → reference
- Replace Temp with Query — Swap temp variables for method calls → reference
- Split Temporary Variable — Assign separate variables for separate purposes → reference
- Remove Assignments to Parameters — Introduce local variables rather than reassigning parameters → reference
- Replace Method with Method Object — Convert a complex method into its own class → reference
- Substitute Algorithm — Swap an algorithm for a clearer alternative → reference