JavaScript Super global variable? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

JavaScript Super global variable?

https://code.sololearn.com/WPjGyWkmNTjI/?ref=app With ECMA6 where does this variable stand? Var? Obviously not let. Not constant either.

12th Jul 2018, 11:39 AM
Akib
Akib - avatar
1 Answer
+ 2
This is old style js syntax, where 'var' could be omitted. If you add "use strict" at the beginning, such syntax will be disabled and you get error displayed.
12th Jul 2018, 1:04 PM
Микола Федосєєв
Микола Федосєєв - avatar