How harshsrivastava1323/letschat works
Project type and purpose
• This is a full-stack real-time chat application built on the MERN stack (MongoDB, Express, React, Node.js) augmented with Socket.io for live messaging, JWT for auth, Tailwind/DaisyUI for styling, and Zustand for client state.
File structure
• Top-level separation:
• frontend/ – React + Vite single-page app
• backend/ – Node.js/Express REST & WebSocket server
• backend/src follows an MVC-style pattern:
• controllers/ – business logic for auth & messages
• models/ – Mongoose schemas (User, Message)
• routes/ – Express routes for HTTP API
• middleware/ – JWT auth guard
• lib/ – DB connection, Cloudinary image service, Socket.io setup, utility helpers
• seeds/ – initial user data
• frontend/src:
• pages/ – route components (Home, Login, Signup, Profile, Settings)
• components/ – UI building blocks (ChatContainer, Navbar, MessageInput, Sidebar, skeleton loaders)
• lib/axios.js – preconfigured HTTP client
• store/ – global Zustand stores (auth, chat, theme)
• constants/ – shared values (e.g., API endpoints)
README for additional insights
• Features: JWT-based Auth, real-time messaging via WebSocket, online user status, error handling, free deployment.
• Tech: MERN + Socket.io + TailwindCSS + DaisyUI + Zustand.