react-live-player v0.1.1
Simple ReactJs Live Media Player Component.
Installation
npm install react-live-player --save
The library have multiply components which can be used along the Player view:
1) DefaultMediaPlayer A default media player for live media stream. Properties
1). mediaPlayback: the mediaplayback that will be used to control the player controls it must be an instead of mediaplayback class.
2). onStop: this is a callback function that will be called when the current media has stoped or stoped by the user.
3) onEnded: this callback function that will be if the current media source has ended.
2) Camera : An Interface class to the user local camera.
It has only one method called "request" which cam be used to request the user camera.
The method return a promised object resolve(mediaplayback) and reject with current error message object.
3) MediaPlayback: A media playback class object interface
4) Player The media player react component view
5) IPlayback The interface abstract class for all media player inherits from.]
6) RecordPlayback: A simple interface to web api recording media playback class.
Uses
var React = require("react"); var Renderer = require("react-dom"); var {DefaultMediaPlayer} = require("react-live-player");
Renderer.render(, document.getElementById("app-id"));