https://github.com/emanuelefavero/nextjs-mongoose
A Next.js project using MongoDB as a database with Mongoose as the ODM
https://github.com/emanuelefavero/nextjs-mongoose
api database db mongodb mongoose next nextjs
Last synced: 6 months ago
JSON representation
A Next.js project using MongoDB as a database with Mongoose as the ODM
- Host: GitHub
- URL: https://github.com/emanuelefavero/nextjs-mongoose
- Owner: emanuelefavero
- License: mit
- Created: 2023-02-01T15:36:04.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-02-01T15:44:10.000Z (over 2 years ago)
- Last Synced: 2025-02-04T16:50:31.186Z (8 months ago)
- Topics: api, database, db, mongodb, mongoose, next, nextjs
- Language: JavaScript
- Homepage: https://nextjs-mongoose-tau.vercel.app
- Size: 32.2 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Next.js Mongoose
This is a Next.js project using MongoDB as a database (Mongoose as the ODM)
> Note: An ODM is an Object Document Mapper. It's a library that allows you to interact with your database using objects
## Live Demo
- [https://nextjs-mongoose-tau.vercel.app/](https://nextjs-mongoose-tau.vercel.app/)
## Getting Started
- Add your MongoDB URI to the `MONGODB_URI` environment variable in `.env.local`
> Note: I'm using MongoDB Atlas
- Install dependencies and run the development server:
```bash
npm i
npm run dev
```## Deploying to Vercel
- Add your MongoDB URI to the `MONGODB_URI` environment variable in Vercel
- Change the server URL in `utils/serverURL.js` to your production Vercel URL