重写内置new和Object.create方法

重写内置new方法 编写_new方法实现内置new xxx()具有的功能。web function Dog(name) { this.name = name; } Dog.prototype.bark = function () { console.log('wangwang'); } Dog.prototype.sayName = function () { consol
相关文章
相关标签/搜索