Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/psidh/nextjs-mongodb-starter
This is a starter repository with already laid out project directory structure for your next full stack project using Next + MongoDB
https://github.com/psidh/nextjs-mongodb-starter
mongodb mongodb-atlas mongoose nextjs react tailwindcss typescript vercel vim
Last synced: about 2 months ago
JSON representation
This is a starter repository with already laid out project directory structure for your next full stack project using Next + MongoDB
- Host: GitHub
- URL: https://github.com/psidh/nextjs-mongodb-starter
- Owner: psidh
- Created: 2024-04-25T13:23:49.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-05-05T17:00:45.000Z (8 months ago)
- Last Synced: 2024-05-05T18:22:29.509Z (8 months ago)
- Topics: mongodb, mongodb-atlas, mongoose, nextjs, react, tailwindcss, typescript, vercel, vim
- Language: TypeScript
- Homepage:
- Size: 60.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Full Stack Next.js + MongoDB + Vercel 🔥
### This is a starter repository with already laid out project directory structure for your next full stack project using Next + MongoDB
Project directory structure
src/
├── app/
│ ├── page.tsx
│ ├── layout.tsx
│ └── globals.css
├── api/
│ └── sample/
│ └── route.ts
├── dbConfig/
│ └── dbConfig.ts
├── models/ (optional)
├── utils/ (optional)
└── interfaces/ (optional, TS only)
.env.SAMPLE1. Make your MongoDB Atlas account
2. Get a Project and create a Database
3. Add the env variables following the .env.SAMPLE projectGitHub Repo: github.com/psidh/nextjs-mongodb-starter
Deployed Link: nextjs-mongodb-starter-psidh.vercel.app/Device : MacBook Air M1 16GB RAM 256GB SSD
OS : macOS Big Sur 11.2.3Steps to run the project:
Fork the repository
Clone the repository```
https://github.com/psidh/nextjs-mongodb-starter
```
```
cd nextjs-mongodb-starter
``````
npm install
``````
npm run dev
```Create a .env.local file in the root directory of the project and add the following environment variables
```bash
MONGODB_URI=your_mongodb_uri
```http://localhost:3000 in your browser
Start coding 🚀