Tag Archives: object

How to iterate over Javascript object properties

How to iterate over Javascript object properties

Here some very common tasks how to iterating over an JavaScript object properties If you have an object, you can’t just iterate it using map(), forEach() or a for..of loop. You will get the following errors: map() function will give you TypeError: items.map is not a function: forEach()  function will give you TypeError: items.forEach is not a function: for..of  will give you TypeError: items […]