Let’s dive into objects Photo by Matt Artz on Unsplash Object.keys(obj) → returns an array of a given object’s property names. Object.values(obj) → returns an array of a given object’s own property values. Object.entries(obj) → returns an array of a given object’s own string-keyed property [key, value] pairs. var user = { name : “John”, profession : …
Continue reading “Accessing an Object’s Keys, Values, and Entries in JavaScript”