Add JS Codestyle ruleset

This adds a JS Codestyle ruleset and fixes the warnings as a result of
this.