Loading repository data…
Loading repository data…
rabeeh-dev / repository
A modern full-stack footwear ecommerce platform with authentication, OTP verification, wallet system, payments, admin dashboard, and a complete shopping experience built using Node.js, Express, MongoDB, and EJS.
HOOF is a modern full-stack ecommerce platform built for footwear lovers.
Browse, discover, and shop the latest shoes — fast, beautiful, and secure. 🛒✨
✨ Features • 🛠️ Tech Stack • ⚙️ Installation • 📸 Screenshots • 🤝 Contributing
HOOF is a sleek, fully-responsive ecommerce website dedicated to footwear. Whether you're hunting for sneakers, formal shoes, or everyday casuals — HOOF has you covered. Powered by a robust Node.js + Express backend with EJS server-side rendering, Passport.js authentication, OTP verification, Wallet system, Referral codes, and a MongoDB database — it delivers a premium shopping experience from browsing to checkout.
┌──────────────────────────────────────────────────────────────┐
│ │
│ 🏠 Home → 👟 Shop → 🛒 Cart → 💳 Checkout → 📦 Orders │
│ │
│ Fast • Secure • Beautiful • Scalable │
│ │
└──────────────────────────────────────────────────────────────┘
╔═══════════════════════════════════════════════════════════════╗
║ 🌟 CORE FEATURES ║
╠═══════════════════════════════════════════════════════════════╣
║ 🔐 User Auth — Register, Login, Google OAuth (Passport.js) ║
║ 📱 OTP Verification via Email ║
║ 👟 Product Catalog with Filters, Search & Categories ║
║ 🛒 Shopping Cart — Add, Remove & Update Quantities ║
║ ❤️ Wishlist — Save Favourite Products ║
║ 💳 Secure Payment Gateway Integration ║
║ 📦 Order Management — Place, Track & View History ║
║ 💰 Wallet System — Refunds & Balance Management ║
║ 🎟️ Coupon Management — Discounts & Promo Codes ║
║ 🔗 Referral Code System ║
║ 🗺️ Address Management — Multiple Delivery Addresses ║
║ 🛡️ Admin Dashboard — Products, Orders, Users, Categories ║
║ 🧭 Breadcrumb Navigation ║
║ 📧 Email Notifications & Password Reset ║
║ 📱 Fully Responsive UI (Mobile-First) ║
╚═══════════════════════════════════════════════════════════════╝
| Layer | Technology |
|---|---|
| 🎨 Frontend | EJS, CSS3, Vanilla JavaScript |
| ⚙️ Backend | Node.js, Express.js |
| 🗄️ Database | MongoDB, Mongoose ODM |
| 🔐 Auth | Passport.js (Local + Google OAuth), bcrypt, Express Session |
| 📧 Email / OTP | Nodemailer |
| 🖼️ File Uploads | Multer |
| 💳 Payments | Razorpay |
| 🔧 Dev Tools | Nodemon, Git, Postman, VS Code |
🌐 BROWSER
│
│ HTTP Request (GET / POST)
▼
┌───────────────────────────────────────┐
│ ⚙️ EXPRESS.JS SERVER │
│ │
│ Routes → Middleware → Controllers │
│ ↓ │
│ Services / Utils │
│ ↓ │
│ EJS Views (SSR) │
└──────────────┬────────────────────────┘
│
│ Mongoose ODM
▼
┌───────────────────────────────────────┐
│ 🗄️ MONGODB │
│ Users | Products | Orders | Cart │
│ Wishlist | Wallet | Coupons | OTP │
└───────────────────────────────────────┘
HOOF/
│
├── 📄 app.js # Express app entry point
├── 📄 backfillReferralCodes.js # Utility: backfill referral codes
├── 📄 package.json
│
├── 📂 config/
│ ├── 📄 db.js # MongoDB connection
│ └── 📄 passport.js # Passport.js strategies (Local + Google)
│
├── 📂 controller/
│ ├── 📄 Address.js # Address CRUD for users
│ ├── 📄 Admin.js # Admin dashboard & user management
│ ├── 📄 AdminCoupon.js # Admin coupon management
│ ├── 📄 AdminProduct.js # Admin product management
│ ├── 📄 Coupon.js # User coupon application
│ ├── 📄 Product.js # Product listing & details
│ ├── 📄 User.js # User profile, auth, OTP
│ └── 📄 UserCheckout.js # Checkout & order placement
│
├── 📂 middleware/
│ ├── 📄 adminAuth.js # Admin route protection
│ ├── 📄 auth.js # User route protection
│ ├── 📄 breadcrumb.js # Breadcrumb navigation builder
│ ├── 📄 cartCount.js # Inject cart count into views
│ ├── 📄 multer.js # Profile image upload config
│ ├── 📄 productMulter.js # Product image upload config
│ └── 📄 wishlistCount.js # Inject wishlist count into views
│
├── 📂 model/
│ ├── 📄 Address.js # Address schema
│ ├── 📄 Admin.js # Admin schema
│ ├── 📄 Cart.js # Cart schema
│ ├── 📄 Category.js # Category schema
│ ├── 📄 Coupon.js # Coupon schema
│ ├── 📄 Order.js # Order schema
│ ├── 📄 Otp.js # OTP schema
│ ├── 📄 Product.js # Product schema
│ ├── 📄 Review.js # Review & rating schema
│ ├── 📄 User.js # User schema
│ ├── 📄 Wallet.js # Wallet schema
│ └── 📄 Wishlist.js # Wishlist schema
│
├── 📂 routes/
│ ├── 📄 Address.js # /address/*
│ ├── 📄 Admin.js # /admin/*
│ ├── 📄 Auth.js # /login, /register, /logout
│ └── 📄 User.js # /shop, /cart, /orders, etc.
│
├── 📂 services/
│ ├── 📄 AdminProduct.js # Admin product business logic
│ ├── 📄 Auth.js # Auth service (OTP, sessions)
│ ├── 📄 Password.js # Password reset logic
│ ├── 📄 Product.js # Product filtering & search
│ ├── 📄 User.js # User profile logic
│ ├── 📄 UserCheckout.js # Checkout business logic
│ └── 📄 Wallet.js # Wallet debit/credit logic
│
├── 📂 utils/
│ ├── 📄 generateOtp.js # OTP generator
│ └── 📄 sendEmail.js # Nodemailer email sender
│
├── 📂 public/
│ ├── 📂 admin/
│ │ ├── 📂 css/ # Admin stylesheets
│ │ └── 📂 js/ # Admin client-side scripts
│ ├── 📂 user/
│ │ ├── 📂 css/ # User stylesheets
│ │ ├── 📂 js/ # User client-side scripts
│ │ ├── 📂 fonts/ # Custom fonts
│ │ └── 📂 images/ # Static UI images
│ └── 📂 uploads/
│ ├── 📂 products/ # Uploaded product images
│ └── 📂 profile/ # Uploaded user profile pictures
│
└── 📂 views/
├── 📂 Admin/
│ ├── 📄 admin-dashboard.ejs
│ ├── 📄 product-management.ejs
│ ├── 📄 add-product.ejs
│ ├── 📄 edit-product.ejs
│ ├── 📄 category-management.ejs
│ ├── 📄 coupon-management.ejs
│ ├── 📄 admin-orders.ejs
│ ├── 📄 admin-order-detail.ejs
│ ├── 📄 user-management.ejs
│ └── 📂 auth/
│ └── 📄 login.ejs
├── 📂 User/
│ ├── 📄 landing.ejs
│ ├── 📄 home.ejs
│ ├── 📄 shop.ejs
│ ├── 📄 product-details.ejs
│ ├── 📄 cart.ejs
│ ├── 📄 checkout.ejs
│ ├── 📄 wishlist.ejs
│ ├── 📄 orders.ejs
│ ├── 📄 order-detail.ejs
│ ├── 📄 order-success.ejs
│ ├── 📄 wallet.ejs
│ ├── 📄 referral.ejs
│ ├── 📄 user-profile.ejs
│ ├── 📄 user-address.ejs
│ ├── 📄 change-email.ejs
│ ├── 📄 about.ejs
│ ├── 📄 contact.ejs
│ ├── 📄 404.ejs
│ └── 📂 auth/
│ ├── 📄 login.ejs
│ ├── 📄 register.ejs
│ ├── 📄 verify-otp.ejs
│ ├── 📄 forgot-password.ejs
│ └── 📄 reset-password.ejs
├── 📂 layouts/
│ ├── 📄 admin.ejs # Admin layout wrapper
│ └── 📄 user.ejs # User layout wrapper
└── 📂 partials/
├── 📂 admin/
│ ├── 📄 overlay.ejs
│ └── 📄 overlay-scripts.ejs
└── 📂 user/
├── 📄 head.ejs
├── 📄 header.ejs
└── 📄 footer.ejs
Make sure you have the following installed:
git clone https://github.com/rabeeh-dev/HOOF.git
cd HOOF
npm install
cp .env.example .env
Fill in your values in the .env file (see section below).
# Development mode (auto-restart with nodemon)
npm run dev
# Production mode
npm start
🌐 App runs on:
http://localhost:3000
http://localhost:3000/admin