Created
May 11, 2022 04:10
-
-
Save Rishabh570/c868c9c6f956b87f04048c39621787fc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const mongooseLoader = require('./mongoose'); | |
const expressLoader = require('./express'); | |
const passportLoader = require('./passport'); | |
const sessionStore = require('./sessionStore'); | |
module.exports = { | |
run: async ({ expressApp }) => { | |
const db = await mongooseLoader.run(); | |
console.log('✌️ DB loaded and connected!'); | |
const mongoSessionStore = sessionStore.run(); | |
await expressLoader.run({ app: expressApp, db, mongoSessionStore }); | |
console.log('✌️ Express loaded'); | |
passportLoader.run(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment