Rewrite jQuery app and add routing

fixes #309
Merge pull request #813 from tastejs/improve-jquery-app

Rewrite jQuery app and add routing and abort on escape