closes #1233
This commit is contained in:
parent
a66f514df7
commit
e82885055b
2 changed files with 2 additions and 2 deletions
|
@ -19,7 +19,7 @@ For example:
|
|||
...
|
||||
```
|
||||
|
||||
We will learn functions (a way to group commands) soon. Looking ahead, let's note that `"use strict"` can be put at the start of most kinds of functions instead of the whole script. Doing that enables strict mode in that function only. But usually, people use it for the whole script.
|
||||
We will learn functions (a way to group commands) soon. Looking ahead, let's note that `"use strict"` can be put at the beginning of the function body instead of the whole script. Doing that enables strict mode in that function only. But usually, people use it for the whole script.
|
||||
|
||||
|
||||
````warn header="Ensure that \"use strict\" is at the top"
|
||||
|
|
|
@ -53,7 +53,7 @@ To fully enable all features of modern JavaScript, we should start scripts with
|
|||
...
|
||||
```
|
||||
|
||||
The directive must be at the top of a script or at the beginning of a function.
|
||||
The directive must be at the top of a script or at the beginning of a function body.
|
||||
|
||||
Without `"use strict"`, everything still works, but some features behave in the old-fashion, "compatible" way. We'd generally prefer the modern behavior.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue