1.0.11 • Published 3 years ago

@teamtv/eventstream-client v1.0.11

Weekly downloads
9
License
ISC
Repository
github
Last release
3 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

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.10

3 years ago

1.0.7

3 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

0.1.0

5 years ago