小编Fra*_*ali的帖子

这内部功能

我的问题是:

function Foo()
{
   this.foo = "bar"; // <- What is "this" here?
}
Run Code Online (Sandbox Code Playgroud)

从我可以告诉它取决于如何Foo使用,即作为构造函数或函数.什么可以this在不同的情况下?

javascript function this

51
推荐指数
4
解决办法
4万
查看次数

标签 统计

function ×1

javascript ×1

this ×1