Monthly archive: September 14, 2014

Express – Route requests from multiple files

If you have started using NodeJS/Express like myself, probably you have this question too! I have a whole lot of app.get, app.post in my app.js file and I don’t like this! Here is a section of my app.js file to give you some perspective! var app = express(); app.get(‘/’, routes.index); app.get(‘/about’, routes.about); app.get(‘/contact’, routes.contact); If [...]