This project demonstrates a simple real-time chat application using gRPC bidirectional streaming in Node.js.
-
Clone this repository.
-
Install the necessary dependencies.
pnpm install
-
Start the gRPC Server: Open your first terminal and run:
node server.js
-
Start Client 1: Open a second terminal and run:
node client.js
You'll be prompted to enter a username (e.g.,
Alice). -
Start Client 2: Open a third terminal and run:
node client.js
You'll be prompted to enter a username (e.g.,
Bob).
Type messages in either client's terminal and press Enter. Messages will appear in the other client's terminal. To exit a client, type exit and press Enter.