@redstonewizard08/youtube-player
v1.3.1
Published
A terrible clone of the YouTube video player.
Downloads
2
Readme
YouTubePlayer
A terrible clone of the YouTube video player.
Installation
- Create a
.npmrc
file in your project with this inside of it:
@redstonewizard08:registry=https://npm.pkg.github.com
- Install the package:
npm install @redstonewizard08/youtube-player
Usage
- Import the library.
// Import the YouTubePlayer utility class.
import YouTubePlayer, { type VideoData } from "@redstonewizard08/youtube-player";
- Create a player instance.
const videos: VideoData[] = [
{
album: "Stardew Valley - Roguelike Mod OST",
artist: "Therm",
title: "Hold Your Ground",
// Note: These work with Data URIs!
poster: "./assets/Hold Your Ground.png",
source: "./assets/Hold Your Ground.mp4",
},
];
YouTubePlayer.createPlaylistPlayer(videos);