We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1d24255 commit 97d2b42Copy full SHA for 97d2b42
constant.js
@@ -0,0 +1,10 @@
1
+/**
2
+ * constant is a single assignmet variable.
3
+ */
4
+
5
+function foo(){
6
+ const i = 1;
7
8
+ var bar = i; // 1
9
+ var i = 2; // error
10
+}
let.js
@@ -0,0 +1,13 @@
+ * let desclares a block scope local variable. let has been in Firefox for a
+ * long time and is now a part of ES6.
+ * IMPORTANT: If outside any block, let is scoped globally else will be scoped
+ * to nearest enclosing block.
+ for(let i = 0; i< 10; i++){
+ // i is visible
11
+ }
12
+ // i is not visible
13
0 commit comments