1.0.5 • Published 5 years ago

livestreams v1.0.5

Weekly downloads
3
License
MIT
Repository
gitlab
Last release
5 years ago

livestreams

React library for embedding a variety of livestreaming platforms into your application.

NPM JavaScript Style Guide

Install

npm install --save livestreams

Usage

import React, { Component } from 'react'

import { Player, Chat } from 'livestreams';
import 'livestreams/dist/index.css'

class ExampleStream extends Component {
  render() {
    return <Player source="twitch" id="Anomaly" autoPlay />
  }
}

class ExampleChat extends Component {
  render() {
    return <Chat source="twitch" id="Anomaly" />
  }
}

Using SSR?

If you're using server-side rendering, you must manually set the origin before creating any elements.

import { setOrigin } from 'livestreams';

setOrigin('localhost');

License

MIT © insertish

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