Hacker News new | comments | show | ask | jobs | submit login

Just because you can doesn't mean you should. A majority of the JS code out has semicolons. Key individuals on the committee responsible for furthering the development of the language recommend always using it. Not including semicolons has shown to result in code errors. It can also introduce build errors when your code is minified. It can also create mental overhead when other developers try to read your code. I just don't get it. Why fight it? Then again, I'm coming from a C/Java background and they just seem so natural to me.



I suspect it is a matter of background, as you imply. Twitter has its roots in Rails, and I believe they also use Scala heavily. Both Ruby and Scala use newline as a statement terminator. GitHub is another Rails shop that avoids semicolons in JS. Zepto.js recently removed the semicolons from its code base, and its author was a core Rails developer.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact

Search: