Safe Refactor Pocket Cards
Recall a compact safety checklist for small refactoring work.
Behavior lock What must stay unchanged during a refactor? The externally visible behavior: return values, side effects, API contract, persisted data, and user-visible outcomes. If one of these changes, switch mental modes and call it feature or bug-fix work. Refactor vs rewrite Which move fits the moment? Prefer refactoring when the behavior must remain and the team can improve structure incrementally. Pressure line We do not have time to refactor; just patch it. Use when a tiny structure move makes the patch safer. Your response I am proposing one local extraction so the patch changes the policy in one named…
Sign up free — one personalized lesson every day, matched to your role and goals.
Already have an account? Sign in