Object.create vs new in terms of prototype inheritance
问题 I have searched a lot about it but I couldn't find any direct answer to it Why we can't access prototype property/method of an object created using Object.create() but we can using new keyword? Let us consider a constructor function Greeting as follows: function Greeting() { } Greeting.prototype.byeBye = function(){ console.log("Have a good day!") } Now I create an object from this constructor using Object.create() method var Stanley = Object.create(Greeting) console.log(Stanley.byeBye())