HouseTrip/javascript — pull request #5 by Karlotcha (2013-11-15 18:45:10+00:00)
Title: Semicolons kill kitties. Don't use them.

Do your best to never use a semicolon.

I know that some good guys use them (like Google guys) - but there are also plenty of them who don't use them (Twitter Bootstrap - Node - Github [(see their style guide)](https://github.com/styleguide/javascript)). But anyway, [arguments from authority](https://yourlogicalfallacyis.com/appeal-to-authority) are bad.

Why not using them? Because they are **optionals** and we are ruby developers. We don't write them everywhere in ruby code and we try to use syntactic sugar.
Writing semicolons everywhere is just **noise**.

About two arguments for using semicolons that I think are bad:

> we can't minify javascript without semicolons.

This is wrong. Some tools to minify javascript may break it, but they are bad tools (and I think some of them have been fixed). Use the ones which don't break it. They should **not break** perfectly valid javascript (and not writing semicolons **is** valid). You can check Twitter Bootstrap sources: they minify their code without semicolons and it works.

> writing semicolons everywhere so we don't forget the ones we really need

I recently saw a bug caused by a missing semicolons... in a file with plenty of them. Writing them doesn't prevent you to forget them. Actually, when I stopped writing them, I learned where I needed them and I actually think it is better to not forget the important ones.

Don't pollute all your codebase with useless characters for no reason :( :( :(

I think this PR will never be merged, but if it is, I will personally clean the whole style guide.

![image](http://25.media.tumblr.com/faa9e89d4524280b85b210e55df1a5d8/tumblr_mgd7xzOyHz1r7ksqyo1_500.gif)