Mismatched parentheses: a quick way to find them?

Chris Tolworthy picture Chris Tolworthy · Sep 29, 2011 · Viewed 34.1k times · Source

I just rearranged a very large JavaScript file. I now get "Unexpected end of input." Somewhere in those hundred of functions, one has lost (or gained) a bracket. What's the quickest way to find it?

Answer

mamoo picture mamoo · Sep 29, 2011

You could try to parse your file with lint: http://www.javascriptlint.com/online_lint.php

If you have problems with the size of the file try to split it into smaller ones...