If you assign a value to a variable that is not explicitly declared (with var, let, const or as an argument of the current function), JavaScript will implicitly create it as a global variable. In a web application, “global” means that it is property of the window object.

#javascript #coding #javascript-tips #web-development #programming

Beware of unsafe implicit globals in JavaScript
1.50 GEEK