DEV Community

Cover image for JavaScript. Memory. Architecture and Lifecycle.

JavaScript. Memory. Architecture and Lifecycle.

Valerii Udodov on October 19, 2021

I'll start this article with a quote that changed the way I think of memory. The way I perceive memory lifecycle in major modern languages (those t...
Collapse
 
ogranada profile image
Andres Granada

Great article, I would only add an extra thing about the hoisting, many people think that let and const declarations wont be hoisted, but you are right, there are hoisted. The reason to get the ReferenceError is because the initialization of those variables has not happened yet and those are referencing to the temporal dead zone (developer.mozilla.org/en-US/docs/W...), throwing the error.

thanks for this great article 👍.

Collapse
 
vudodov profile image
Valerii Udodov

Good call! Thanks!

Collapse
 
sanzhardanybayev profile image
Sanzhar Danybayev

If you have introduced primitive and reference data types, you wouldn't be confused when using assign operator.

Collapse
 
sanzhardanybayev profile image
Sanzhar Danybayev

Don't take it as offence. I really enjoyed your article. But exactly that issue worried me)

Collapse
 
vudodov profile image
Valerii Udodov

Not at all, however not sure I follow what concerns you :)

Collapse
 
raftlabs profile image
RaftLabs - AI App Dev Agency

Thanks a lot for the article, very detailed and articulate!

Collapse
 
vudodov profile image
Valerii Udodov

Thanks, glad you enjoyed it :)

Collapse
 
posandu profile image
Posandu

Nice!

Collapse
 
vudodov profile image
Valerii Udodov

Glad you liked it!

Collapse
 
vudodov profile image
Valerii Udodov

Thank you! Appreciate the feedback!

Collapse
 
asimdahall profile image
Asim Dahal

Awesome article, really loved it. Learned a lot

Collapse
 
vudodov profile image
Valerii Udodov

Great to hear!