it's best practice to use "strict mode".
JS โฉ concepts โฉ strict mode โฉ always use strict mode
in strict mode๏ผ
โ eval has its own scope in strict mode.
โ no accidental global variable in sloppy modeโ๏ธ
โ no deplicate parametersโ. ( ๐ more ... )
โ can't delete variables/functions. ( ๐ more ... )
โ no octal literals ( ๐ more ... )
parameter
eval
global variable
eval of strict mode code does not introduce new variables into the surrounding scopearrow-up-right
itHome โฉ ไฝ ไธๅฏไธ็ฅ็ JavaScript ไบไธไบarrow-up-right โฉ
#Day12๏ผ็ Strict Mode ๅฆไฝๆฝๅฑใ้ๆๆผไบฎๆณใ(1)arrow-up-right
Strict modearrow-up-right
Last updated 3 years ago