npm.io
1.0.5 • Published 1 year ago

@types/react-youtube-embed

Licence
MIT
Version
1.0.5
Deps
1
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/react-youtube-embed

Summary

This package contains type definitions for react-youtube-embed (https://github.com/escaladesports/react-youtube-embed#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-youtube-embed.

index.d.ts

import * as React from "react";

declare namespace YouTubeEmbed {
    interface YouTubeEmbedProps {
        id: string;

        /**
         * Set an aspect ratio or percentage.
         * @default "16:9"
         */
        aspectRatio?: string | undefined;

        /**
         * Prepends a string to the embed URL (before the YouTube ID).
         * @default "https://www.youtube.com/embed/"
         */
        prependSrc?: string | undefined;

        /**
         * Appends a string to the embed URL.
         * @default ""
         */
        appendSrc?: string | undefined;

        width?: number | string | undefined;
    }
}

declare class YouTubeEmbed extends React.Component<YouTubeEmbed.YouTubeEmbedProps> {}

export = YouTubeEmbed;

Additional Details

  • Last updated: Tue, 20 May 2025 1734 GMT
  • Dependencies: @types/react

Credits

These definitions were written by Charles Salmon.