JavaScript syntax: Difference between revisions

Content deleted Content added
(
Reverted 1 good faith edit by 193.206.251.4 using STiki
Line 804:
<syntaxhighlight lang=JavaScript>
var a, b, c, d, e;
[a, b] = [3, 4];
[a, b] = [3, 4]; //Will cause an 'Uncaught ReferenceError: Invalid left-hand side in assignment(…)' in chrome
alert(a + ',' + b); // displays: 3,4
e = {foo: 5, bar: 6, baz: ['Baz', 'Content']};