Wednesday, May 21, 2014

javascript scope var vs this.

Here is the code.
"var" and "this" they don't share the same scope or context. They cannot be replaced by the other.
"var" could only be use internally. It could not be referred externally. But "this" can be referred externally.

In another article, we know "this" could be changed.

No comments:

Post a Comment