#435 - moving remaining app.js logic to base template
#435 - removing app.js