Post

Rob Palmer
Rob Palmer@robpalmer2·
This conflicts with the mental model is that each closure should only retain one binding. Which leads to unintuitive memory leaks in practice.
English
0
0
0
7.3K
Rob Palmer
Rob Palmer@robpalmer2·
This has been the case in engines for years. If engines could find a way to fix it, JS apps would release objects sooner & use less memory. I have wondered if a JS toolchain ("a bundler") could transparently optimize this, e.g. with a combo of function hoisting + bind()
English
7
0
70
5.8K
Paylaş