var a = function foo(){
this.confusing = 'hell yeah';
function boo(){
this...
}
}
In function boo()
which call inside of foo()
, will this
be defined for foo()
element?
var a = function foo(){
this.confusing = 'hell yeah';
function boo(){
this...
}
}
In function boo()
which call inside of foo()
, will this
be defined for foo()
element?
Inside the boo
function, this
will reference the boo
function object, or "window" if you will. This is similar to the stacking of scopes in python, if you're familiar with that.