javascript-reference-data-types-1 Flashcards
1
Q
What is an object in JavaScript?
A
containers for named values called properties or methods
2
Q
How do you create an object literal?
A
create a variable
and list values inside separated by commas.
3
Q
What is a property in relation to JavaScript objects?
A
A variable that is part that stores data within the object .
4
Q
When should you use bracket notation over dot notation with objects?
A
when property name is a variable.
characters that can’t be used with dot notation
5
Q
How do you remove a property from an object?
A
delete then use dot notation to specify what is being deleted.