There have been some middleware changes on the new version of express and I have made some changes in my code around some of the other posts on this issue but I can\'t get a
Simple solution if your are using express and doing
const router = express.Router();
make sure to
module.exports = router ;
at the end of your page