update post: Closure and this - How are variables resolved within functions?

This commit is contained in:
2020-08-03 09:32:15 +05:30
parent 567a8e144a
commit eef2c48d44
+1 -1
View File
@@ -140,7 +140,7 @@ function outer() {
## `this` lookup ## `this` lookup
Earlier, we looked at how normal variables get resolved in a function. But whenever you write `this.someThing`, the value of `this` does NOT get resolved in the same way. It is called as a `ThisExpression`, which gets resolved specially. Earlier, we looked at how normal variables get resolved in a function. But whenever you write `this.someThing`, the value of `this` does NOT get resolved in the same way. It is known as a `ThisExpression`, which gets resolved specially.
Before going further, lets take a small detour. Before going further, lets take a small detour.