Skip to content

Commit 3c62ecc

Browse files
authored
Merge pull request #2753 from vigu86/patch-1
Remove redundant word in Possible Mistakes section
2 parents 20da240 + db074cd commit 3c62ecc

File tree

1 file changed

+1
-1
lines changed
  • 2-ui/2-events/01-introduction-browser-events

1 file changed

+1
-1
lines changed

2-ui/2-events/01-introduction-browser-events/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ button.onclick = sayThanks;
160160
button.onclick = sayThanks();
161161
```
162162

163-
If we add parentheses, then `sayThanks()` becomes is a function call. So the last line actually takes the *result* of the function execution, that is `undefined` (as the function returns nothing), and assigns it to `onclick`. That doesn't work.
163+
If we add parentheses, then `sayThanks()` becomes a function call. So the last line actually takes the *result* of the function execution, that is `undefined` (as the function returns nothing), and assigns it to `onclick`. That doesn't work.
164164

165165
...On the other hand, in the markup we do need the parentheses:
166166

0 commit comments

Comments
 (0)