https://github.com/hassanshehzad1/e-commerce
Basic-ecommerce application using Node.js and Express.js with ejs as template engine and mongoDB for database. This project include user authentication, session managment, flash messaging and CRUD operations for products
https://github.com/hassanshehzad1/e-commerce
backend expressjs html-css-javascript javascript mongodb nodejs
Last synced: 3 months ago
JSON representation
Basic-ecommerce application using Node.js and Express.js with ejs as template engine and mongoDB for database. This project include user authentication, session managment, flash messaging and CRUD operations for products
- Host: GitHub
- URL: https://github.com/hassanshehzad1/e-commerce
- Owner: hassanshehzad1
- Created: 2024-11-07T11:52:13.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-11-07T12:09:00.000Z (over 1 year ago)
- Last Synced: 2026-01-03T12:24:59.293Z (6 months ago)
- Topics: backend, expressjs, html-css-javascript, javascript, mongodb, nodejs
- Language: CSS
- Homepage:
- Size: 2.63 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
E-commerce store
This is a basic e-commerce application using Node.js and Express.js, with ejs as a template engine and mongodb as a database. This project includes user authentication, session managment, flash messaging and basic crud operations for products
Key features
User authencition
Uses session for login managment with express-session
Database inetgration
MongoDB connected via mongoose
Template Engine
EJS to render dynamic pages.
File Upload multer
is a setup for handling useful pages(useful for product image).
EJS to render dynamic pages.
Environmental variables
Managed thorough dotenv for sensitive information.
EJS to render dynamic pages.
Falsh Messages
Show feedback to users for login/logout pages..
Project structure
project-root/
├── config/ # Configuration files
│ └── db/
│ └── conn.js # MongoDB connection
├── controllers/ # Controllers for handling logic
├── middlewares/ # Custom middleware (e.g., flash)
├── models/ # Mongoose schemas/models
├── public/ # Static files (CSS, images, etc.)
├── routes/ # Route definitions
│ ├── userRoutes.js
│ ├── ownerRoutes.js
│ ├── productRoutes.js
│ └── indexRoute.js
├── views/ # EJS view templates
│ ├── index.ejs
│ ├── user/
│ ├── owner/
│ └── product/
├── .env # Environment variables
├── .gitignore # Ignore node_modules, .env, etc.
├── app.js # Main application file
└── package.json