Finding memory leaks with Chrome Dev tools
summary
Shows how Chrome DevTools diagnose a real memory incident in a chat app: use Chrome Task Manager, take heap snapshot comparisons, filter by class filter "detached" to find retained DOM nodes, run the JavaScript profiler (GC shows ~34% time) and the Performance monitor to spot rising unreleased memory. Root cause is a Redux selector running on every keystroke that allocates many objects; fixes move selectors up and introduce a memoized selector plus removal of useless state. Two PRs roll out and the leak is resolved in about 1.5 weeks.
AI-written summary · about
