Making the js proper coffeescript so it can be maintained :)