Our volunteers haven't translated this article into عربي yet. Join us and help get the job done!
You can also read the article in English (US).


SyntaxError: missing ] after element list

Error type


What went wrong?

There is an error with the array initializer syntax somewhere. Likely there is a closing bracket ("]") or a comma (",") missing.


Incomplete array initializer

var list = [1, 2,

var instruments = [

var data = [{foo: 'bar'} {bar: 'foo'}];

Correct would be:

var list = [1, 2];

var instruments = [

var data = [{foo: 'bar'}, {bar: 'foo'}];

See also

Document Tags and Contributors

 المساهمون في هذه الصفحة: nmve, fscholz
 آخر مَن حدّثها: nmve,