My Learning Curve

Feed / Josh Comeau's blog

The “const” Deception

Monday, April 24, 2023

The “const” keyword in JavaScript is used to create constants, variables that can't change. Curiously, though, we do seem to be able to edit objects and arrays that are created using “const”. In this tutorial, we're going to dig into the incredibly-important distinction between “assignment” and “mutation” in JavaScript.

Keep reading.


Read original article ↗