How to use react-youtube - 4 common examples

To help you get started, we’ve selected a few react-youtube examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pedsmoreira / premiere-player / src / stores / playerStore.js View on Github external
pause(): void {
    this.state = YouTube.PlayerState.PAUSED;
    this.pauseDispatcher.dispatch();
  }
github pedsmoreira / premiere-player / src / components / player / PlayerAudio.js View on Github external
onStateChange(event) {
        if (this.target !== event.target) {
            this.target = event.target
            this.target.setVolume(100)
            this.target.setPlaybackQuality('small')
        }

        if (event.data === Youtube.PlayerState.PLAYING) {
            this.props.onLoad()
        }
    }
github pedsmoreira / premiere-player / src / stores / playerStore.js View on Github external
play(): void {
    this.state = YouTube.PlayerState.PLAYING;
    this.playDispatcher.dispatch();
  }
github idyll-lang / idyll / packages / idyll-components / src / youtube.js View on Github external
componentDidMount() {
    this.setState({ mounted: true });
    YouTube = require('react-youtube').default;
  }

react-youtube

React.js powered YouTube player component

MIT
Latest version published 2 years ago

Package Health Score

58 / 100
Full package analysis

Popular react-youtube functions