Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

loop on an object

let obj = { first: "John", last: "Doe" };

for (const key in obj){
console.log(key)
consol.log(obj[key])
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #loop #object
ADD COMMENT
Topic
Name
3+7 =