I am trying to require a file and afterwards pass it to a var. I am following this tutorial to create a authentication system. After writing the server.js file and trying to
Remember to export your routes.js.
routes.js
In routes.js, write your routes and all your code in this function module:
exports = function(app, passport) { /* write here your code */ }