A modern, full-stack web application built with cutting-edge technologies for seamless product management and secure authentication.
Threadora is a production-ready full-stack application demonstrating professional software engineering practices, including:
- Secure Authentication with JWT and Google OAuth integration
- RESTful API with comprehensive validation and error handling
- Modern Frontend with responsive UI and state management
- MongoDB integration with Mongoose ORM
- Cloud Image Storage using ImageKit
- Professional Code Architecture with middleware pattern and service layer
Node.js + Express 5.2.1
βββ Authentication
β βββ JWT (jsonwebtoken)
β βββ Passport.js with Google OAuth 2.0
β βββ Password hashing (bcryptjs)
βββ Database
β βββ MongoDB + Mongoose 9.6.3
βββ File Management
β βββ Multer for uploads
β βββ ImageKit for cloud storage
βββ Validation & Security
β βββ express-validator
β βββ CORS enabled
β βββ Cookie Parser
βββ Logging
βββ Morgan HTTP logger
React 19.0 + Vite
βββ State Management
β βββ Redux Toolkit
βββ Routing
β βββ React Router v7
βββ Styling
β βββ Tailwind CSS v4
βββ HTTP Client
β βββ Axios
βββ UI/UX
βββ React Toastify (notifications)
βββ Responsive Design
Threadora/
βββ Backend/
β βββ src/
β β βββ app.js # Express app configuration
β β βββ config/ # Database & environment config
β β βββ controllers/ # Business logic handlers
β β βββ middlewares/ # Auth, validation, error handling
β β βββ models/ # MongoDB schemas (User, Product)
β β βββ routes/ # API endpoints
β β βββ services/ # Business logic services
β β βββ validators/ # Request validation rules
β β βββ utils/ # Async handler utilities
β βββ server.js # Entry point
β βββ package.json # Dependencies
β
βββ Frontend/
βββ src/
β βββ app/ # App configuration
β β βββ App.jsx # Root component
β β βββ app.routes.jsx # Route definitions
β β βββ app.store.js # Redux store
β βββ features/ # Feature modules
β βββ auth/ # Authentication feature
β β βββ components/ # Login, Signup, Protected routes
β β βββ hooks/ # useAuth hook
β β βββ pages/ # Auth pages
β β βββ services/ # Auth API calls
β β βββ states/ # Redux slices
β βββ shared/ # Shared components
βββ vite.config.js # Build configuration
- β JWT-based authentication
- β Google OAuth 2.0 integration
- β Secure password hashing with bcryptjs
- β Protected routes with middleware
- β Cookie-based session management
- β CRUD operations for products
- β Image upload with cloud storage
- β Comprehensive input validation
- β Error handling and logging
- β Separation of concerns (Controllers, Services, Models)
- β Middleware pattern for request processing
- β Global error handling
- β Request validation layer
- β Async/await error wrapper utilities
- β Modern React with Hooks
- β Redux state management
- β Client-side routing
- β Responsive Tailwind CSS design
- β Toast notifications for user feedback
- β Protected routes and role-based access
- Node.js (v16 or higher)
- MongoDB local instance or MongoDB Atlas connection
- Google OAuth credentials
cd Backend
npm install
# Create .env file with:
# PORT=5000
# MONGODB_URI=your_mongodb_uri
# JWT_SECRET=your_secret_key
# GOOGLE_CLIENT_ID=your_client_id
# GOOGLE_CLIENT_SECRET=your_client_secret
# IMAGEKIT_PUBLIC_KEY=your_imagekit_key
# IMAGEKIT_PRIVATE_KEY=your_private_key
# IMAGEKIT_URL_ENDPOINT=your_url_endpoint
# Development
npm run dev
# Production
npm run startcd Frontend
npm install
npm run devVisit http://localhost:5173 (or your configured Vite port)
POST /api/auth/signup- User registrationPOST /api/auth/login- User loginPOST /api/auth/logout- User logoutGET /api/auth/google- Google OAuth
GET /api/products- Get all productsPOST /api/products- Create product (authenticated)GET /api/products/:id- Get product by IDPUT /api/products/:id- Update product (authenticated)DELETE /api/products/:id- Delete product (authenticated)
- JWT Authentication - Stateless, secure token-based auth
- CORS Protection - Configured for trusted origins
- Request Validation - express-validator middleware
- Password Security - Bcryptjs hashing with salt rounds
- Error Handling - No sensitive information leakage
- HTTP Only Cookies - Secure cookie configuration
- Environment Variables - Sensitive data protection
- Express 5.2.1 - Latest web framework
- Mongoose 9.6.3 - ODM for MongoDB
- Passport.js - Authentication middleware
- express-validator - Request validation
- bcryptjs - Secure password hashing
- ImageKit - Cloud image management
- React 19.0 - Latest React version
- Redux Toolkit - State management
- React Router v7 - Client-side routing
- Tailwind CSS v4 - Utility-first CSS
- Axios - Promise-based HTTP client
- Vite - Next-gen build tool
This project demonstrates:
- β Clean code architecture with separation of concerns
- β Middleware pattern for cross-cutting concerns
- β Service layer for business logic
- β Comprehensive error handling
- β Input validation and sanitization
- β RESTful API design principles
- β Component-based UI architecture
- β State management with Redux
- β Environment-based configuration
- β Responsive design patterns
- Backend Documentation (if available)
- Frontend Documentation (if available)
- Design System
npm run dev # Start development server with hot reload
npm run start # Start production servernpm run dev # Start Vite development server
npm run build # Build for production
npm run lint # Run ESLint
npm run preview # Preview production buildFeel free to fork this repository and submit pull requests to help improve Threadora.
This project is licensed under the ISC License - see LICENSE file for details.
Threadora is built with a focus on modern development practices, scalability, and maintainability. It serves as a comprehensive example of full-stack JavaScript development with industry best practices.
Created with β€οΈ using Node.js, React, and MongoDB