/RxJS-WebSocket

Basic demo for RxJS and WebSocket in Angular and Node JS

Primary LanguageTypeScript

RxJS-WebSocket

Basic demo for RxJS and WebSocket in Angular and Node JS

Uses

  • RxJS(rxjs)
  • WebSocket(ws)
  • Angular CLI
  • Typescript

Cloning The GitHub Repository

$ git clone https://github.com/santoshshinde2012/RxJS-WebSocket.git

Quick Install

Once you've downloaded the demo and installed all the prerequisites, you're just a few steps away from starting to develop your demo application.

The demo comes pre-bundled with a package.json file that contain the list of modules you need to start your application.

To install the dependencies in client and server, run this in the application folder from the command-line:

$ npm install

This command does a few things:

  • First it will install the dependencies needed for the application to run.
  • If you're running in a development environment, it will then also install development dependencies needed for testing and running your application.
  • When the npm packages install process is over, npm will initiate a bower install command to install all the front-end modules needed for the application
  • To update these packages later on, just run npm update

Running Your Server Application

Run your application using npm:

$ npm start

Your application should run on port 8999 with the development environment configuration, so in your browser just go to http://localhost:8999/

Running Your Client Application

Run your application using npm:

$ npm start

Your application should run on port 4200 with the development environment configuration, so in your browser just go to http://localhost:4200/

Try to open same URL http://localhost:4200/ in two or more browser windows and play with the broadcast button.

alt text

About Me