For the below code,
var customer={
name: "Tom Smith",
speak: function(){
return "My name is " + this['name'];
},
address: {
street: '123 Main St',
city: "Pittsburgh",
state: "PA"
}
};
Below is my visualisation of customer object,
My question:
Does customer
object inherit properties(built-ins) of Object.prototype
only?
Are the properties(built-ins) of Object
function type object are also for the purpose of inheritance?
If yes, What is the syntax for customer
object to inherit Object
properties?