摘要:
function Person(name,age){ this.name = name; this.age = age; } var person1 = new Person('jay',24); console.log(person1.prototype); //undefined console 阅读全文
posted @ 2021-05-29 14:36
皮杰克
阅读(56)
评论(0)
推荐(0)
摘要:
1.创建新对象 2.将this绑定到该对象 3.执行构造函数代码,将属性绑定到新对象 4.返回该对象 注意:新对象的__proto__要指向构造函数的prototype 阅读全文
posted @ 2021-05-29 11:37
皮杰克
阅读(57)
评论(0)
推荐(0)
浙公网安备 33010602011771号