Moving routing into application.js