๐ฐfunction hoisting
identifier hoisted at top of scope, value initialized to a function value (instantly).
JS โฉ scope โฉ hoisting โฉ function hoisting
with a function declaration๏ผ
identifier๏ผ hoisted to the top of its scope.
referencing a function in block (FiB) outside block
sloppy mode: โ hoisted / initialized to undefined (outside block)
strict mode: โ ReferenceError (invisible outside block)โ
related topics
Last updated
Was this helpful?