Skip to content

Latest commit

 

History

History
76 lines (55 loc) · 2.29 KB

README.md

File metadata and controls

76 lines (55 loc) · 2.29 KB

chat-app-next-socket

Built With 📦

Node.js Next.js Next.js Next.js Github

Open Source? No!

How to build & run? 🎯

Make sure you have Nodejs installed anc clone this repository on local PC.

node --version
git clone <this-repo-name>
  • Install the dependencies:

    cd client && npm install
    cd ..
    cd server && npm install
    • Installs all the dependencies required by the project.
  • Run dev server

    cd server && npm start
    cd ..
    cd client n&& npm run dev
  • Build

     npm run build
  • Run Server

     cd dist
     npx serve -s -l 80
  • To contribute, make pull request for your own branch:

    git add .
    git commit -m "<COMMIT-MESSAGE>"
    git push origin <NAME-OF-THE-BRANCH>

Description

We have all encountered chat over the web, that can be Facebook, Instagram, Whatsapp and the list goes on. Just to give a bit of context, you send a message to a person or a group, they see the message and reply back. Simple yet complex.

To develop a chat app you would need to be aware of new messages as soon as they arrive. Usually, to get information from the server you need send an HTTP request. With websockets, the server lets you know when there is new information without asking it.

In this project, we leveraged the real-time communication provided by Socket.io to create an open chat application that allows users to send and receive messages from several users on the application. You will also learn how to detect the users who are online and when a user is typing.