A full-stack Book Store application built as a dynamic project using the MERN Stack.
The application helps manage users, books, and authentication with email verification with notifications.
The backend is deployed and can be accessed at
https://book-store-mern-stack-bewg.onrender.com
The frontend is deployed and can be accessed at
https://book-store-mern-stack-prj.vercel.app/
- User Registration & Login
- Email Verification using OTP
- Secure Authentication (JWT)
- Book Management (Add / View / Update)
- MongoDB Database Integration
- Clean and Responsive UI
- Environment-based Configuration
- Ready for Deployment
- React (Vite)
- HTML, CSS, JavaScript
- Node.js
- Express.js
- MongoDB
- Nodemailer (Email Service)
- JWT Authentication
- OTP-based email verification implemented
- Gmail App Password used for secure email sending
- Nodemailer configured with environment variables
- Node.js installed
- MongoDB database running
- Gmail App Password for email verification
Book-Store/
├── backend/
│ ├── controllers/
│ ├── models/
│ ├── routes/
│ ├── middleware/
│ ├── config/
│ ├── utils/
│ ├── .env
│ └── server.js
├── frontend/
│ ├── src/
│ │ ├── components/
│ │ ├── pages/
│ │ ├── context/
│ │ ├── utils/
│ │ └── App.jsx
│ ├── index.html
│ └── vite.config.js
└── README.md
- Navigate to the backend directory:
cd backend - Install dependencies:
npm install
- Create a
.envfile with the following variables:MONGODB_URI=your_mongodb_connection_string PORT=5000 JWT_SECRET=your_jwt_secret EMAIL_USER=your_gmail_email EMAIL_PASS=your_gmail_app_password - Start the backend server:
(For production:
npm run dev
npm start)
- Navigate to the frontend directory:
cd frontend - Install dependencies:
npm install
- Start the development server:
npm run dev
- Open your browser and navigate to the displayed local URL (usually http://localhost:5173)
To build the frontend for production:
npm run buildPOST /api/v1/auth/register - Register a new user
POST /api/v1/auth/login - Login user
POST /api/v1/auth/verify-otp - Verify OTP
POST /api/v1/auth/forgot-password - Forgot password
PUT /api/v1/auth/reset-password - Reset password
GET /api/v1/auth/me - Get current user
GET /api/v1/auth/logout - Logout user
This project demonstrates a complete full-stack application with modern web development write the code and secure authentication mechanisms.