Interview practice question
A long-running dashboard leaks memory over days
Frontend Engineering · Async JavaScript and the Browser · Experienced
A monitoring dashboard left open on office screens for days slowly consumes more memory until the browser crashes. How do you fix it?
What a strong answer covers
Your AI report card counts how many of these ideas you cover.
- Unbounded data accumulation (arrays of updates).
- Bound buffers (ring buffers), downsample old data.
- Clean up listeners on reconnects.
- Detached DOM from chart re-renders.
- Periodic soft refresh as safety net.
Practise this topic
Start without signing up. Sign in free to get an AI report card on your answer.