this用法详解

2017-07-20  本文已影响0人  馋中解禅

1.全局this

console.log(this===window);//输出:true

2.函数或方法中的this

3.原型中的this

4.对象中的this

5.DOM事件回调中的this

6.HTML中的this

7.call,apply,bind区别

上一篇 下一篇

猜你喜欢

热点阅读