react-youtube-embed
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/react-youtube-embed package

1.0.3 • Public • Published

react-youtube-embed

A responsive YouTube embed component for React.

Install

With npm:

npm install --save react-youtube-embed

With Yarn:

yarn add react-youtube-embed

Usage

import YouTube from 'react-youtube-embed'
 
...
 
<YouTube id='A71aqufiNtQ' />

Options

  • aspectRatio: Set an aspect ratio or percentage. Default: "16:9"
  • prependSrc: Prepends a string to the embed URL (before the YouTube ID). Default: "https://www.youtube.com/embed/"
  • appendSrc: Appends a string to the embed URL. Default: ""

Package Sidebar

Install

npm i react-youtube-embed

Weekly Downloads

441

Version

1.0.3

License

MIT

Unpacked Size

249 kB

Total Files

9

Last publish

Collaborators

  • amadoa
  • dalewray
  • codevelopit
  • mastaaaron
  • escasports
  • tbaustin
  • ken85rose