Loading…
A short voice session: one question, one follow-up, then instant feedback — up to 5 minutes.
Migrate incrementally rather than all at once: enable Strict Mode per subtree, fix what it reveals, convert components when you touch them or when they block a goal, protect behaviour with tests, and track progress with lint rules and metrics.
A big-bang rewrite stalls feature work and is risky. Start by upgrading React and fixing deprecation warnings, then enable Strict Mode on one subtree at a time to reveal unsafe lifecycles, missing effect cleanup and impure rendering. Prioritize components that block goals, such as code that prevents upgrades or causes bugs, and convert others opportunistically when features touch them. Write behaviour-level tests before refactoring so regressions are caught. Add lint rules that forbid new legacy patterns, keep a shared guide with examples, and measure the share of migrated code. Class components still work, so leaving stable, untouched ones as they are can be a reasonable choice.