From the course: Objects in JavaScript: A Dynamic Data Structure
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Necessary vocabulary: Keys, values, and properties - JavaScript Tutorial
From the course: Objects in JavaScript: A Dynamic Data Structure
Necessary vocabulary: Keys, values, and properties
Let's review a few more key vocabulary terms property, key, and value. I have discussed these terms at length earlier in the course, but it is important not to mix them up as you are technically communicating to others. The key in an object is the list of property names. The value is the data assigned to the key. Here is an example. Here, you see an object that has the key of name, and the key is assigned to the value of John. Now, here, I will merely make a mention that keys and their values can be reassigned. However, I won't go into too much depth of the different object methods used to rename. Helicopter view here is that if I wanted to rename the key of name to neighbor, it could be done just as you see here. Also, as you know, or may have expected, the keys value can also be reassigned as you see here. The object obj1 was first declared with the value of an array containing the string red and a number one. The value on the second line of code was reassigned with an array…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.