📜var

🚧 under construction

JSvariable ⟩ var

Stop using var ( 👉see why)

( var is a statement, not a declaration)

declares a variable in function scope / global scope ( and does a lot of side effects).

var

👉 compare: function declaration

in global scope,

👉 global var / function is global object property❗️

Variable Statement

📘 JS specVariable Statement

Last updated