Skip to content

Commit 2ec3e7c

Browse files
Update en-US.mdx (#36)
Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
1 parent 7200741 commit 2ec3e7c

File tree

1 file changed

+1
-1
lines changed
  • questions/explain-how-this-works-in-javascript

1 file changed

+1
-1
lines changed

questions/explain-how-this-works-in-javascript/en-US.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ const person = new Person('John');
105105
person.showThis(); // Person {name: 'John'}
106106

107107
const showThisStandalone = person.showThis;
108-
showThisStandalone(); // `undefined` because all parts of a class' body are strict mode.
108+
showThisStandalone(); // `undefined` because in JavaScript class bodies, all methods are strict mode by default, even if you don't add 'use strict'
109109
```
110110

111111
### Explicitly binding `this`

0 commit comments

Comments
 (0)