0.0.4 • Published 3 years ago

youplayer v0.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

YouPlayer

YouPlayer is perfect Youtube Player wrapper. Every link that make user go straight to youtube is disable. so, user always stay on your website to watch exclusive content.

1. Installation

npm i youplayer

2. Import Project

import YouPlayer from "youplayer"
import "youplayer/dist/style.css"
<div id="video"></div>

<script>
    const app = YouPlayer({
      el : "#video",
      videoId : "_7EwGJmjT5E"
    })
</script>

4. Methods

you can use method below to change player experience. usage example :

app.loadVideo("SkIk7txs1aY")
method namedescription
loadVideo(videoId : string)to change video on existing player
playVideo()to play video
pauseVideo()to pause video
stopVideo()to stop video

Thank You

This library built using vite, tailwind css and svelte.