detecting JS language mode for tools

Brian Terlson Brian.Terlson at microsoft.com
Fri Jan 24 09:32:40 PST 2014


> You don't get "let", "function" block scoping, "yield" or other incompatible constructs. (let and yield aren't a reserved word in ES5 "loose)

It is true that there is some weirdness with let/const and block scoping in non-strict mode, but these issues can be sufficiently mitigated. IE11 has shipped let/const support and block-scoped functions with (mostly) backwards compatible semantics. For example, `let let = 1;` works in IE11 today outside of strict mode.


More information about the es-discuss mailing list