Answers for "javascript loop through onject"

10

javascript iterate over object

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

Object.keys(obj).forEach(function(key) {
    console.log(key, obj[key]);
});
Posted by: Guest on September-11-2019

Code answers related to "javascript loop through onject"

Code answers related to "Javascript"

Browse Popular Code Answers by Language