loop through object property values code example
Example 1: javascript loop through object
var person = {"name":"bob", age:45};
for (var property in person) {
console.log(person[property]);
}
Example 2: javascript iterate through object attributes
for (var prop in obj) {
if (Object.prototype.hasOwnProperty.call(obj, prop)) {
// do stuff
}
}