What is "use-strict"

For example, use a variable that has not been declared, use reserved words in code, or use language resources that have already been declared obsolete.

Without enabling the restricted mode (use Strict), the code below is executed without launching any exceptions, although it is bad practice to use the variable "name" without declaring it:

function minhaFuncao() {
    nome = "Caio Proiete";
    // ...
}

minhaFuncao();

If we enable restricted mode (use Strict), an exception will be made to notify that we have a problem in the code:

function minhaFuncao() {
    "use strict";

    // 0x800a13b2 - JavaScript runtime error: Variable undefined in strict mode
    nome = "Caio Proiete";
    // ...
}

minhaFuncao();