Object sits at the very base of the JS Data-Structures. Whatever other data-types we say (Arrays, Promises, Date, Strings, Numbers, Functions, Boolean, Maps, Sets, etc.) --- have Object as their upstream in the prototype chain
so they may access all its properties and methods.
Now, even Object has got a set of its own properties & methods, which it might access when it needs.
Object.prototype
gives set of its properties and methods.
Object.assign
Now returns some function.
The strange thing is I expected assign() function
to be a method up in the Object-prototype chain. Why is it not present? Shouldn't ideally be it should be there ?? If NOT, how object is able to use it?
Also, Object.prototype.prototype will give you null
as there is nothing above it.
consider: