Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-video-component

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-video-component

Simple video component for react

  • 1.4.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

React video component

Development

npm install
npm run dev

Utilization

import ReactVideoComponent from 'react-video-component';

Warning

This repo should not be used in production.

How to

The component can have every listener the origin video tag has.
For example <video sources={[url..]} metadataloaded={this._onLoaded.bind(this)}/> calls the function _onLoaded, with the event as argument. The video is so accessible through event.target.

A list of events can be found here.

Props:

PropertyTypeDefaultDescription
sourcesArray[]Defines sources for the video. Must be an array of objects or strings, representing the url of the video. If object is given, it must have `src` key representing the url.
styleObject{}Style object that will apply to video tag element.
classNameString""Name of the class that will apply to video tag element.
attributesObject{}Standard props of the video element ( e.g. "loop", "controls" ).
controlsBooltrueShow or hide controls.
autohideBooltrueAutomatically hide controls and overlay ( if "fixedoverlay" set to false ) when playing.
autohidecursorBooltrueAutomatically hide cursor when playing.
overlayBooltrueShow or hide overlay.
fixedoverlayBoolfalseDisable autohide for overlay.
shortcutsBooltrueEnable or disable keyboard shortcuts.
tabIndexString"1"Tab index of the wrapper element.
widthString"auto"Width of the video element.
heightString"100%"Height of the video element.

Known issues

  • Weird IE render issues. Custom controls will be disabled.

Keywords

FAQs

Package last updated on 19 Nov 2016

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc