Skip to main content
btheo.com btheo.com > press start to play
NEW POST: NODE.JS SECURITY 2025 OPEN FOR FREELANCE 10+ YEARS EXP REACT × NODE × AWS NEW POST: NODE.JS SECURITY 2025 OPEN FOR FREELANCE 10+ YEARS EXP REACT × NODE × AWS
TIL · 06 JAN 2025 · NOTE #003 ESC
TIL NOTE #003

Stop Overusing useEffect

Many performance issues in React apps come from unnecessary useEffect hooks.

If you’re using useEffect() just to sync state:

  • Check if derived state can be used instead.
  • Consider lifting state up instead of syncing between components.
  • Ensure dependencies are properly set to avoid unnecessary re-renders.

React’s best performance trick? Rendering less.