Skip to content

Latest commit

ย 

History

15 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ LazyText

A modern real-time messaging application built with Flutter, Node.js, Express, MongoDB, and Socket.IO.

LazyText enables users to authenticate securely, discover other users, and exchange messages instantly through WebSocket-powered communication.


๐Ÿ“ฑ Screenshots

Welcome Screen

Create Account


Users List

Real-Time Messaging

---

โœจ Features

๐Ÿ” Authentication

  • User Registration
  • User Login
  • JWT Authentication
  • Protected API Routes
  • Password Hashing using BCrypt

๐Ÿ’ฌ Real-Time Messaging

  • One-to-One Chat
  • Socket.IO Integration
  • Instant Message Delivery
  • Persistent Chat History
  • Real-Time Synchronization

๐Ÿ‘ฅ User Management

  • Browse Registered Users
  • User Discovery Screen
  • Secure User Sessions

๐ŸŽจ Modern UI

  • Dark Theme Design
  • Responsive Layout
  • Reusable Flutter Widgets
  • Modern Chat Bubbles
  • Smooth Navigation

๐Ÿ›  Tech Stack

Frontend

  • Flutter
  • Dart
  • Dio
  • Shared Preferences
  • Socket.IO Client

Backend

  • Node.js
  • Express.js
  • Socket.IO
  • JWT Authentication
  • BCryptJS

Database

  • MongoDB
  • Mongoose

Cloud Services

  • Cloudinary

๐Ÿ—๏ธ Architecture

Flutter App
     โ”‚
     โ–ผ
 REST API (Dio)
     โ”‚
     โ–ผ
Express Backend
     โ”‚
     โ–ผ
MongoDB

Flutter App
     โ”‚
     โ–ผ
Socket.IO Client
     โ”‚
     โ–ผ
Socket.IO Server
     โ”‚
     โ–ผ
Real-Time Communication

๐Ÿ“‚ Project Structure

lib/
โ”‚
โ”œโ”€โ”€ common/
โ”‚   โ””โ”€โ”€ color_extension.dart
โ”‚
โ”œโ”€โ”€ models/
โ”‚   โ””โ”€โ”€ user_model.dart
โ”‚
โ”œโ”€โ”€ screens/
โ”‚   โ”œโ”€โ”€ auth/
โ”‚   โ”œโ”€โ”€ chat/
โ”‚   โ””โ”€โ”€ home/
โ”‚
โ”œโ”€โ”€ services/
โ”‚   โ”œโ”€โ”€ api_service.dart
โ”‚   โ””โ”€โ”€ socket_service.dart
โ”‚
โ”œโ”€โ”€ widgets/
โ”‚   โ”œโ”€โ”€ custom_button.dart
โ”‚   โ”œโ”€โ”€ message_bubble.dart
โ”‚   โ”œโ”€โ”€ message_input.dart
โ”‚   โ”œโ”€โ”€ round_textfield.dart
โ”‚   โ””โ”€โ”€ user_tile.dart
โ”‚
โ””โ”€โ”€ main.dart

๐Ÿ” Authentication Flow

User Signup/Login
        โ”‚
        โ–ผ
Backend Validation
        โ”‚
        โ–ผ
JWT Generation
        โ”‚
        โ–ผ
SharedPreferences
        โ”‚
        โ–ผ
Protected API Access

โšก Real-Time Messaging Flow

User A Sends Message
         โ”‚
         โ–ผ
Socket.IO Server
         โ”‚
         โ–ผ
MongoDB Storage
         โ”‚
         โ–ผ
Receiver Socket
         โ”‚
         โ–ผ
User B Receives Instantly

๐Ÿ“ก REST API Endpoints

Authentication

POST /api/auth/signup
POST /api/auth/login
POST /api/auth/logout
GET  /api/auth/check

Messaging

GET  /api/message/users
GET  /api/message/:userId
POST /api/message/send/:receiverId

๐Ÿ”Œ Socket Events

Client โ†’ Server

connection
disconnect

Server โ†’ Client

newMessage
onlineUsers

โš™๏ธ Environment Variables

Create a .env file inside the backend folder:

PORT=5001

MONGODB_URI=your_mongodb_uri

JWT_SECRET=your_secret_key

CLOUDINARY_CLOUD_NAME=your_cloud_name

CLOUDINARY_API_KEY=your_api_key

CLOUDINARY_API_SECRET=your_api_secret

๐Ÿš€ Installation

Backend Setup

git clone https://github.com/yourusername/lazytext.git

cd backend

npm install

npm run dev

Flutter Setup

cd lazy_text

flutter pub get

flutter run

๐ŸŽฏ Key Learning Outcomes

This project helped me gain hands-on experience with:

  • Flutter Application Development
  • REST API Integration
  • JWT Authentication
  • MongoDB Data Modeling
  • Socket.IO Real-Time Communication
  • Backend Development with Express.js
  • Secure Authentication Flows
  • Full-Stack Application Architecture

๐Ÿ”ฎ Future Improvements

  • Online / Offline Presence
  • Typing Indicators
  • Read Receipts
  • Image Messaging
  • Push Notifications
  • Group Chats
  • Voice Messages
  • Message Search
  • End-to-End Encryption

๐Ÿ“ˆ Resume Highlights

This project demonstrates:

โœ… Full-Stack Development

โœ… Mobile App Development

โœ… REST API Design

โœ… Authentication & Authorization

โœ… MongoDB Database Design

โœ… WebSocket Communication

โœ… Real-Time Systems

โœ… Production-Oriented Architecture


Project Title for Resume

LazyText โ€“ Real-Time Chat Application (Flutter, Node.js, MongoDB, Socket.IO)

About

Real Time Chat App

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages