# react-native-live-stream

> a react-native module for live stream play and publish, support ios and android platform

Latest version **1.0.1** (published 2019-07-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-native-live-stream
pnpm add react-native-live-stream
yarn add react-native-live-stream
bun add react-native-live-stream
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; large bundle.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2019-07-20 |
| First published | 2019-02-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 75.6 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 93 |
| Author | Wonday |
| Maintainers | wonday |
| Keywords | react-component, react-native, android, ios, live, stream, livestream |

## Links

- npm: https://www.npmjs.com/package/react-native-live-stream
- Repository: https://github.com/wonday/react-native-live-stream
- Issues: https://github.com/wonday/react-native-live-stream/issues
- npm.io page: https://npm.io/package/react-native-live-stream

## Alternatives

- [byte-size](https://npm.io/package/byte-size.md) — 2.1M weekly downloads
- [speed-limiter](https://npm.io/package/speed-limiter.md) — 16.0K weekly downloads
- [@powersync/node](https://npm.io/package/@powersync/node.md) — 10.9K weekly downloads
- [@ledgerhq/coin-cardano](https://npm.io/package/@ledgerhq/coin-cardano.md) — 1.0K weekly downloads
- [@jayesol/jayeson.lib.streamfinder](https://npm.io/package/@jayesol/jayeson.lib.streamfinder.md) — 1.0K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2019-07-20
- 1.0.0 — 2019-02-15
- 0.0.0 — 2019-02-13

## README

# react-native-live-stream
[![npm](https://img.shields.io/npm/v/react-native-live-stream.svg?style=flat-square)](https://www.npmjs.com/package/react-native-live-stream)

a react-native module for live stream play and publish

## ChangeLog

v1.0.1
1. fix readme

v1.0.0
1. initial release


## Installation
### Using npm

    npm install react-native-live-stream --save
    react-native link react-native-live-stream

### Using yarn
    yarn add react-native-live-stream
    react-native link react-native-live-stream

## After Installation
### Android
 no addition operation, you can use it now

### iOS
1. Add framework search path

In Xcode, project ```Build Settings``` find ```Framework search path```, 
add ```$(PROJECT_DIR)/../node_modules/react-native-live-stream/ios/libs``` to it.

2. Add framework

drag ```node_modules/react-native-live-stream/ios/libs/NodeMediaClient.framework``` to Xcode ```frameworks``` folder，select ```create folder references``` then OK.

## LivePlayer

### Feature
Protocol: RTMP/RTMPT/RTMPE/RTSP/HLS/HTTP(S)-FLV
Video codec: H.264, H.265,FLV, VP6, MPEG4
Audio codec: AAC, MP3, SPEEX, NELLYMOSER, ADPCM_SWF, G.711

### Usage

```
import {LivePlayer} from "react-native-live-stream";

<LivePlayer source={{uri:"rtmp://live.hkstv.hk.lxdns.com/live/hks"}}}
   ref={(ref) => {
       this.player = ref
   }}
   style={styles.video}
   paused={false}
   muted={false}
   bufferTime={300}
   maxBufferTime={1000}
   resizeMode={"contain"}
   onLoading={()=>{}}
   onLoad={()=>{}}
   onEnd={()=>{}}
/>
```

---
_Source: https://npm.io/package/react-native-live-stream · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
