What is 'strict mode'?
What strict mode does:
- you cannot use undeclared variables inside it,
- it changes previously accepted "wrong syntax" into errors,
- it doesn't allow mistyping a variable name (which outside the strict mode creates a new global variable),
- any assignment to a non-writable / getter-only / non-existing property or non-existing variable/object will throw an error.