Skip to content
JS
JavaScript error

SyntaxError

The JavaScript exception "missing ] after element list" occurs when there is an error with the array initializer syntax somewhere. Likely there is a closing square bracket (]) or a comma (,) missing.

Reference entryJavaScriptFetched
SyntaxError: missing ] after element list (Firefox)
As listed by MDN Web Docs
SyntaxError: Unexpected token ';'. Expected either a closing ']' or a ',' following an array element. (Safari)
As listed by MDN Web Docs
Category
SyntaxError
Severity
error
Runtime
both
or press Cmd/Ctrl + Enter. The text is only sent to this site to match it.
Source: MDN Web Docs. Data fetched 2026-09-25T01:48:37.274Z.