A full-stack social networking web app built using modern web technologies like Node.js, Express, and MongoDB. This project represents my journey through backend development — from setting up authentication manually to implementing advanced tools like Passport.js, JWT, Google OAuth, and Kue for background jobs.
| Category | Technologies / Libraries |
|---|---|
| Backend | 🟩 Node.js • ⚙️ Express.js |
| Database | 🗄️ MongoDB • 🧩 Mongoose |
| Authentication | 🔐 Passport.js (Local & Google OAuth) • 🔑 JWT |
| Utilities | 🍪 Cookie-Parser • 🔒 Crypto • 🧂 Bcrypt |
| Styling & Frontend | 🎨 EJS • 💅 SCSS/SASS • ⚡ Noty.js • ⚙️ AJAX |
| Email & Jobs | 📬 Nodemailer • 🧵 Kue • 🧱 Redis |
| File Uploads | 🗂️ Multer |
| Architecture | 🧠 MVC Pattern |
✅ User Authentication & Authorization
- Manual sign up / login using sessions
- Authentication via Passport.js (Local + Google OAuth)
- Token-based APIs using JWT
✅ Profile Management
- Update profile details and upload avatar with Multer
- Flash messages using Noty.js
✅ Post & Comment System
- Users can create, delete, and comment on posts
- Asynchronous operations using AJAX, Promises, and async/await
✅ Email Service & Password Reset
- Forgot Password feature using Nodemailer
- Secure password reset and update mechanism using Crypto and Bcrypt
✅ Background Jobs
- Used Kue and Redis to manage email jobs in background threads
✅ API Integration
- Created REST APIs for posts, comments, and user authentication with JWT
✅ Styling
- Beautiful UI built with modular SASS/SCSS
- Node.js + Express.js fundamentals
- Working with MongoDB using Mongoose ODM
- Authentication (Manual + Passport.js + JWT + Google OAuth 2.0)
- File upload with Multer
- Sending mails with Nodemailer
- Implementing background jobs using Kue & Redis
- Flash messages and alerts with Noty.js
- Securing data using Crypto and Bcrypt
- Building dynamic frontends with AJAX, Promises, and async/await
- Organizing and compiling SASS/SCSS files
- Following the MVC architectural pattern
codeial/
│
├── assets/ # SCSS, JS, images
├── config/ # Passport, Mongoose, Kue, etc.
├── controllers/ # App logic
├── mailers/ # Nodemailer templates
├── models/ # Mongoose schemas
├── routes/ # Express routes
├── views/ # EJS templates
├── index.js # Main server file
└── package.json
git clone https://github.com/<your-username>/codeial.git
cd codeialnpm installCreate a .env file in the root folder and add the following:
MONGODB_URI=your_mongodb_url
SESSION_SECRET=your_secret_key
GOOGLE_CLIENT_ID=your_client_id
GOOGLE_CLIENT_SECRET=your_client_secret
GOOGLE_CALLBACK_URL=http://localhost:8000/users/auth/google/callback
JWT_SECRET=your_jwt_secret
REDIS_URL=redis://127.0.0.1:6379If using WSL or Linux:
redis-servernpm startThe app will run at 👉 http://localhost:8000
This project uses Nodemailer to send password reset and other notification emails.
Configure your email credentials in /config/nodemailer.js for sending real emails.
- Users can sign up or log in manually
- Authentication handled with Passport.js
- Social login with Google OAuth 2.0
- JWT-based authentication for APIs
- Forgot password → Generates token via Crypto → Sends mail via Nodemailer
- User clicks link → Updates password securely (hashed with Bcrypt)
Used Kue with Redis to handle asynchronous jobs (like sending mails). Each job runs in a background worker thread to improve performance.
"scripts": {
"start": "node index.js",
"dev": "nodemon index.js"
}- Create a user manually or log in using Google
- Create, delete, and comment on posts
- Check live flash messages using Noty.js
- Click “Forgot Password” to receive an email
- Reset password via secure tokenized link
- Try asynchronous post deletion via AJAX
Ansh Gupta 📍 India 🔗 LinkedIn • GitHub
💡 “Still learning, building, and exploring full-stack technologies every day.”
🚧 This is not the complete project — I’m still building it and adding more crazy features soon! Stay tuned for updates like real-time chat, notifications, and more! 🚀
