Introduce require.js - js is now organized in modules.

not really a nice solution as jquery does not support AMD, but this
seems to be the only clean way that allows having html template files
separated from js scripts in the static folder.
use html templates for views via the text plugin of require.js