this的指向问题?

1.普通函数内部使用this,那么this指向window,在严格模式下,则指向undefined.javascript // 'use strict' //若是使用严格模式则this指向undefined function getthis () { console.log(this);//window } getthis(); 2.若是在对象的方法内调用,则this指向该
相关文章
相关标签/搜索