JavaScript Variable Scope And Properties

Table of the JavaScript variable types detailing their scopes and properties.

 varletconst
Global scopeYesNoNo
Functional scopeYesYesYes
Block scopeNoYesYes
Can be changed?YesYesNo
Can be re-declared?YesNoNo
Can be hoisted?YesNoNo

Add new comment

The content of this field is kept private and will not be shown publicly.
CAPTCHA
5 + 6 =
Solve this simple math problem and enter the result. E.g. for 1+3, enter 4.
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.