react-html-video

React HTML5 Video

Usage no npm install needed!

<script type="module">
  import reactHtmlVideo from 'https://cdn.skypack.dev/react-html-video';
</script>

README

Getting started

npm install
npm start

Example

import React, { Component } from 'react'
import Video from './Video'

export default class VideoExample extends Component {
  constructor (props) {
    super(props)

    this.state = {}
  }

  render () {
    var videoSrc = [
      'bunny.mp4',
      'bunny.ogg'
    ]

    return (
      <Video
        width={400}
        src={videoSrc}
      />
    )
  }
}