Primitive Data Types
A primitive data is also called a basic value.
A non-primitive data is also called a complex value.
Here's an example:
let teaTime = false; // teaTime is currently a Boolean
teaTime = 7; // teaTime is now a Number
teaTime = "Seven"; // teaTime is now a String
The snippet above first used the
teaTime variable to store a Boolean value.
Then, we changed
teaTime from a Boolean to a Number.
Afterward, the variable got changed to a String data type.
In other words, you can use the