Support packaging as a Chrome Packaged App

Requires pre-compiling the templates, but otherwise the basics seem to be working.
Need a recent Chrome Canary build, unfortunately. Should still work as a node
app as before with no changes.