摘要: this 1、在普通函数下,this的指向是window。2、有事件源,指向事件源本身。3、在定时器下(除es6),指向window。 setTimeout(()=>{ console.log(this) },0) 4、在对象下,this指向的是自己本身。 5、回调函数下的this,一般指向wind 阅读全文
posted @ 2019-08-30 14:51 迷失地 阅读(141) 评论(0) 推荐(0) 编辑