Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit 60e77ae

Browse files
authored
Fix a mistake in "Type Checking JavaScript Files"
1 parent dba5de9 commit 60e77ae

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pages/Type Checking JavaScript Files.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,10 @@ class C {
4545
method() {
4646
this.constructorOnly = false // error, constructorOnly is a number
4747
this.constructorUnknown = "plunkbat" // ok, constructorUnknown is string | undefined
48-
this.methodOnly = 'ok' // ok, but y could also be undefined
48+
this.methodOnly = 'ok' // ok, but methodOnly could also be undefined
4949
}
5050
method2() {
51-
this.methodOnly = true // also, ok, y's type is string | boolean | undefined
51+
this.methodOnly = true // also, ok, methodOnly's type is string | boolean | undefined
5252
}
5353
}
5454
```

0 commit comments

Comments
 (0)