Objects vs Primitive Values

Every value in JavaScript is either a primitive or an object

This tells us how the value is stored in memory, either in a "pass by value" or a "pass by reference" approach.

Primitives are atomic values

They can't be broken down; they are the "smallest" possible data type.

Objects are compound values

Objects are comprised of either other objects and/or primitive values. Therefore they can be broken down to smaller bits.

Primitive values are immutable

We can't change the value of a primitive, we can only assign the value of one primitive to another one. This means the same variable will hold a new primitive value, not a modified one.

Objects are mutable

We can change objects in place because of the "pass by reference" approach