摘要:
将类数组转换未数组的几种方法 1. Array.prototype.slice.call() function sum(a,b,c) { let args = Array.prototype.slice.call(arguments) console.log(args.reduce((sum, cu 阅读全文
摘要:
继承实现的几种方式 1.借助call实现继承 function p1() { this.name = 'p1' this.say = function () { console.log(this.name) } } var Parent1 = p1 Parent1.prototype.show = 阅读全文