hoangvvo / nextjs-mongodb-app

A Next.js and MongoDB web application, designed with simplicity for learning and real-world applicability in mind.
https://nextjs-mongodb.now.sh/
MIT License
1.54k stars 289 forks source link

Use express-session #92

Closed hoangvvo closed 4 years ago

hoangvvo commented 4 years ago

This PR replaces next-session with express-session.

Why? express-session is a more battle-tested library. next-session is not being deprecated.

Back when I first started this project, next-connect was not made, so there was no where to use express-session in next.js. Therefore, I develop next-session with an API (withSession) that can be used with API Routes.

Now that we have next-connect, it is more ideal to use express-session.

vercel[bot] commented 4 years ago

This pull request is being automatically deployed with Vercel (learn more). To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/hoangvvo/nextjs-mongodb-app/o53gdeysz ✅ Preview: https://nextjs-mongodb-app-git-use-express-session.hoangvvo.vercel.app