JavaScript/Strict mode

The strict mode
Strict mode can be enabled by placing '"use strict";' at the beginning of a script, before other statements:

It can also be enabled for a single function only:

Strict mode ensures the following:
 * New variables need to be declared with "var"; "var" is no longer optional.
 * Attempts to write to non-writable variables throw an error rather than silently doing nothing.
 * Attempts to delete undeletable properties throw an error rather than silently doing nothing.
 * Octal numerals are disallowed.
 * Etc.

Strict mode is available since JavaScript 1.8.5, i.e. ECMAScript version 5.