The post discusses unexpected behaviors related to garbage collection and closures in JavaScript. It explains scenarios where an array buffer leaks memory and why certain functions cause retention of variables that are no longer needed. The post clarifies how JavaScript engines handle memory scopes and outlines a problem case where a cleanup function causes memory to be unnecessarily retained until explicitly nullified.

3m read timeFrom jakearchibald.com
Post cover image
Table of contents
JavaScript engines are reasonably smartThe problem case

Sort: