You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -437,7 +437,7 @@ However, do note that:
437
437
438
438
There's no simple explanation for `this`; it is one of the most confusing concepts in JavaScript because it's behavior differs from many other programming languages. The one-liner explanation of the `this` keyword is that it is a dynamic reference to the context in which a function is executed.
439
439
440
-
A longer explanation follows is that `this` follows these rules:
440
+
A longer explanation is that `this` follows these rules:
441
441
442
442
1. If the `new` keyword is used when calling the function, meaning the function was used as a function constructor, the `this` inside the function is the newly-created object instance.
443
443
2. If `this` is used in a `class``constructor`, the `this` inside the `constructor` is the newly-created object instance.
@@ -4619,7 +4619,7 @@ myFunction();
4619
4619
4620
4620
There's no simple explanation for `this`; it is one of the most confusing concepts in JavaScript because it's behavior differs from many other programming languages. The one-liner explanation of the `this` keyword is that it is a dynamic reference to the context in which a function is executed.
4621
4621
4622
-
A longer explanation follows is that `this` follows these rules:
4622
+
A longer explanation is that `this` follows these rules:
4623
4623
4624
4624
1. If the `new` keyword is used when calling the function, meaning the function was used as a function constructor, the `this` inside the function is the newly-created object instance.
4625
4625
2. If `this` is used in a `class``constructor`, the `this` inside the `constructor` is the newly-created object instance.
0 commit comments