Skip to content

AmenAdem/nestjs-websocket

Repository files navigation

NestJS Socket.IO Chat App

This is a simple chat application built using NestJS and Socket.IO. It allows users to engage in real-time communication by sending and receiving messages through a WebSocket connection established by Socket.IO.

Features

  • Real-time messaging: Users can send and receive messages instantly without the need to refresh the page.
  • Multiple users: The app supports multiple users participating in the chat simultaneously.
  • Name display: Each message in the chat displays the name of the user who sent it.
  • Responsive design: The app is designed to be mobile-friendly and adjusts to different screen sizes.

Technologies Used

  • NestJS: A progressive Node.js framework for building efficient, reliable, and scalable server-side applications.
  • Socket.IO: A library that enables real-time, bidirectional, and event-based communication between the browser and the server using WebSocket.

Installation

To run the chat app locally, follow these steps:

  1. Clone the repository: git clone <repository-url>
  2. Install dependencies: npm install
  3. Start the server: npm start
  4. Access the app in your browser at http://localhost:3000

Usage

  1. Open the chat app in your browser.
  2. Enter your name in the provided input field.
  3. Type your message in the message input field.
  4. Click the "Send" button or press Enter to send the message.
  5. Your message will be displayed in the chat along with your name.
  6. Other participants' messages will appear in real-time.

Example

Here's an example of how the app looks:

NestJS Socket.IO Chat App

Contributions

Contributions to this project are welcome. If you find any issues or would like to enhance the app's functionality, feel free to submit a pull request.

License

This project is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published