@asaje/sse-push-event-client
TypeScript icon, indicating that this package has built-in type declarations

1.0.6 • Public • Published

SSE-PUSH-EVENT

Description

Lightweight package for SSE push events handling

Installation

npm i @asaje/sse-push-event-client

or

yarn add @asaje/sse-push-event-client

How to use

import {
  initPushEvent,
  joinPushEventRoom,
  addPushEventListener,
} from '@asaje/sse-push-event-client';

initPushEvent('http://localhost:3000/events');

joinPushEventRoom('test');

addPushEventListener('TEST', (data) => {
  console.log('Received: ', data);
});

/@asaje/sse-push-event-client/

    Package Sidebar

    Install

    npm i @asaje/sse-push-event-client

    Weekly Downloads

    1

    Version

    1.0.6

    License

    MIT

    Unpacked Size

    5.25 kB

    Total Files

    10

    Last publish

    Collaborators

    • asaje379