3 ms·
You might want to check out this great article on semicolon insertion: http://inimino.org/~inimino/blog/javascript_semicolons http://inimino.org/~inimino/blog/
by ufo 14y ago
You might want to check out this great article on semicolon insertion:
http://inimino.org/~inimino/blog/javascript_semicolons http://inimino.org/~inimino/blog/javascript_semicolons
Basically, you can almost always remove the semicolons without trouble and more often then not problems occur from semicolons not being inserted then from them being inserted in unexpected positions. The "returning an object literal" case is the only common case where a semicolon is mischeviously inserted.
- esrauch 14y agoI wasn't trying to express a strong stance on the issue, just pointing out what the Google's js style guide says, the + on the next line wouldn't be allowed there (nor .) http://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml#Semicolons http://google-styleguide.googlecode.com/svn/trunk/javascript...