mim Armand
1 min readAug 19, 2019

--

Great article! Thanks for sharing!
I was curious, however, to find out, how you concluded that the reference to those arrays ( as well as the nested functions ) are instantiated only once?
If I was to guess I wouldn’t be able to say that Javascript holds on to those references (inside the scope of a separate function) between calls. I would think there isn’t any difference between the two provided snippets as far as the creation of those variables (memory references) is concerned. but would love to learn if that’s not the case?

--

--

mim Armand
mim Armand

Written by mim Armand

Sr Solutions Architect / Technology evangelist and Consultant / Teacher / Artist / Everything!

No responses yet