Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javasript object

let anObject = {left: 1, right: 2};
console.log(anObject.left);
// → 1
delete anObject.left;
console.log(anObject.left);
// → undefined
console.log("left" in anObject);
// → false
console.log("right" in anObject);
// → true
Source by eloquentjavascript.net #
 
PREVIOUS NEXT
Tagged: #javasript #object
ADD COMMENT
Topic
Name
9+9 =