1.2.2 • Published 5 years ago

react-trailer v1.2.2

Weekly downloads
12
License
ISC
Repository
github
Last release
5 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

5 years ago

1.2.1

5 years ago

0.0.1-beta.49

5 years ago

1.1.2

5 years ago

0.1.2-beta.6

5 years ago

0.0.1-beta.46

5 years ago

0.0.1-beta.48

5 years ago

0.1.2-beta.4

5 years ago

0.1.2-beta.3

5 years ago

0.1.2-beta.2

5 years ago

0.1.1

5 years ago

0.1.1-beta.4

5 years ago

0.1.0-beta.5

5 years ago

0.1.0-beta.4

5 years ago

0.1.0

5 years ago

0.1.0-beta.3

5 years ago

0.1.0-beta.1

5 years ago

0.1.0-beta.0

5 years ago

0.0.1-beta.8

5 years ago

0.0.1-beta.16

5 years ago

0.0.1-beta.7

5 years ago