1.0.11 • Published 4 years ago

@teamtv/eventstream-client v1.0.11

Weekly downloads
9
License
ISC
Repository
github
Last release
4 years ago

EventStream Client

Simple Client for the teamtv event stream API

Installation

npm install --save @teamtv/eventstream-client

Usage

import { EventStream, SSEEventStreamSource } from '@teamtv/eventstream-client';

const es = new EventStream(
  new SSEEventStreamSource("<teamtv eventstream endpoint>")
);

es.on("shot", (attributes) => {
  if (attributes.result === "GOAL") {
    console.log("Shot", attributes);
  }
});
1.0.11

4 years ago

1.0.9

4 years ago

1.0.8

4 years ago

1.0.10

4 years ago

1.0.7

4 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago

0.1.0

6 years ago