1.2.2 • Published 4 years ago

react-trailer v1.2.2

Weekly downloads
12
License
ISC
Repository
github
Last release
4 years ago

NPM

npm i react-trailer --save

Import the components needed to build your video player:

import {
  VideoPlayer,
  Viewer,
  Controls,
  PlayButton,
  FullscreenButton,
  ProgressControl,
  DurationControl,
} from 'react-trailer';
<VideoPlayer>
  <Viewer>
    <Viewer.Source src="http://dl5.webmfiles.org/big-buck-bunny_trailer.webm" type="video/webm" />
  </Viewer>
  <Controls>
    <ProgressControl />
    <PlayButton>
      {({ isPlaying }) => (isPlaying ? 'Pause' : 'Play')}
    </PlayButton>
    <FullscreenButton>
      {({ isFullscreen }) => (isFullscreen ? 'Close' : 'Fullscreen')}
    </FullscreenButton>
    <DurationControl />
  </Controls>
</VideoPlayer>

Install dependencies, build the source files and preview

git clone https://github.com/Naimikan/react-trailer.git
npm install
npm run build && npm start
1.2.2

4 years ago

1.2.1

4 years ago

0.0.1-beta.49

4 years ago

1.1.2

4 years ago

0.1.2-beta.6

4 years ago

0.0.1-beta.46

4 years ago

0.0.1-beta.48

4 years ago

0.1.2-beta.4

4 years ago

0.1.2-beta.3

4 years ago

0.1.2-beta.2

4 years ago

0.1.1

4 years ago

0.1.1-beta.4

4 years ago

0.1.0-beta.5

4 years ago

0.1.0-beta.4

4 years ago

0.1.0

4 years ago

0.1.0-beta.3

4 years ago

0.1.0-beta.1

4 years ago

0.1.0-beta.0

4 years ago

0.0.1-beta.8

4 years ago

0.0.1-beta.16

4 years ago

0.0.1-beta.7

4 years ago