JavaScript: Object.entries

By Xah Lee. Date: . Last updated: .

New in JS2017.

Object.entries(obj)
Return a Array of [key, value] pairs that are obj's string property keys that are own and enumerable.
console.log( Object.entries({a:3, b:4}) );
// [ [ "a", 3 ], [ "b", 4 ] ]
BUY
ΣJS
JavaScript in Depth

JS Obj Reference

Object Object

prototype