My JavaScript recipes
The code block will iterate through the object and check to see if the key exists in the Object object. If it does, then it will get the value stored at the key in the object and assign it to the element variable.
Shortcut: for.in
for (const key in object) {
if (Object.hasOwnProperty.call(object, key)) {
const element = object[key];
}
}