app.use([
require('./routes/home'),
require('./routes/auth'),
require('./routes/about'),
require('./routes/premium'),
])
app.use([
require('./routes'),
])
const routes = require("./routes/index")
routes.forEach(route => app.route(route));
'use strict';
const fs = require('fs');
const path = require('path');
const basename = path.basename(__filename);
const routes = [];
fs
.readdirSync(__dirname)
.filter(file => {
return (file.indexOf('.') !== 0) && (file !== basename) && (file.slice(-9) === 'Routes.js');
})
.forEach(file => {
routes.push(...require(path.join(__dirname, file)));
});
module.exports = routes;