不知為什么照著老師寫一直是 (intermediate value) init is not a function報(bào)錯(cuò)解決方法
最后自己把extend方法換成了
lightHalf.prototype = Object.create(light.prototype);
lightHalf.prototype.constructor = lightHalf;
這種繼承方法才得已解決,
最后自己把extend方法換成了
lightHalf.prototype = Object.create(light.prototype);
lightHalf.prototype.constructor = lightHalf;
這種繼承方法才得已解決,
舉報(bào)
2017-09-24
可能是你的init()方法寫錯(cuò)了