Fix jshint issues on handlebars + requirejs

* moving mainjs with requirejs config into seperate template file
* fixes jshint issues
* Fixes #86