Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

loop through object element names javascript

object = {key1: "data", key2: 255}
for (let key in object) {
  console.log(key);
}
// output:
// key1
// key2
 
PREVIOUS NEXT
Tagged: #loop #object #element #names #javascript
ADD COMMENT
Topic
Name
7+9 =