Chaining assignments as part of a var declaration will create global variables unintentionally.
For example:
(function foo() {
var a = b = 0;
})()
console.log('a: ' + a);
console.log('b: ' + b);
Will result in:
Uncaught ReferenceError: a is not defined
'b: 0'
In the above examp...