Socket
Socket
Sign inDemoInstall

@billionkeys/react-native-eventsource

Package Overview
Dependencies
0
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @billionkeys/react-native-eventsource

React-Native component for EventSource: Server-Sent Events for iOS and Android


Version published
Maintainers
1
Install size
909 kB
Created

Readme

Source

react-native-eventsource

Dependencies Build License PRs Welcome

Description

A react-native component for EventSource: Server-Sent Events for iOS and Android.

Install

yarn add @billionkeys/react-native-eventsource

How to use it?

import EventSource from "@billionkeys/react-native-eventsource";

const url = "https://domain/sse";
const eventSource = new EventSource(url);

eventSource.onopen = () => {
  console.debug("onopen");
};
eventSource.onmessage = message => {
  console.debug(message);
};
eventSource.onerror = err => {
  console.error(err);
};

License

MIT © billionkeys

FAQs

Last updated on 14 Apr 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc