//------------
let person = {
name: 'John Doe',
age: 22
}
let e = document.getElementById('task-title');
/* Object.getOwnPropertyNames()
Returns an array containing the names of all of the given object's own enumerable and
non-enumerable properties. */
console.log(typeof person, person);
console.log(Object.getOwnPropertyNames(person));
console.log(typeof e);
console.log(Object.getOwnPropertyNames(e));
console.dir(e);
For my custom person object the methods Object.getOwnPropertyNames works however it does not work the Element Object Why ?
&
Are the DOM Element Objects any different than a custom object? If yes How?