Refactoring
Goal
Improve structure without changing behavior.
Best Tools
- Claude Code
- Codex
- Aider
Recommended Prompt
Refactor for readability and maintainability without changing behavior.
Preserve public interfaces.
Step-by-Step
- identify safe scope
- refactor in small steps
- run tests
CLI Examples
aider
claude
IDE Examples
- use Cursor for local refactor loops with diff review
Review Checklist
- behavior preserved
- public API unchanged
Common Mistakes
- mixing refactor and feature change
Team Standard
Separate behavior changes from refactors when possible.