摘要: 【问题描述】 setTimetout/setInterval中this指针指向window,以下是一个小demo: 我想要的是this指定demoChange对象,但是function中的this指向的是window。 【解决方案】 1、保存this变量 2、改变函数内部this指向:bind 3、 阅读全文
posted @ 2019-07-17 10:26 WANNANANANA 阅读(337) 评论(0) 推荐(0)