Svelte Video Player screenshot

Svelte Video Player

Author Avatar Theme by Meigo
Updated: 5 Aug 2021
134 Stars

Basic video player component for svelte

Overview

The Svelte Video Player is a basic video player component for Svelte, Sapper, and legacy apps. It comes with tabbable controls that respond to key presses, such as enter, space, and arrows. This player also supports pausing previously playing video player instances when a new player is started. While fullscreen functionality is disabled on iPhone, it functions smoothly on both desktop and mobile browsers.

Features

  • Tabbable controls with support for key presses
  • Pauses previously playing video player instances when a new player is started
  • Smooth functionality in both desktop and mobile browsers

Installation

To install the Svelte Video Player, follow these steps:

  1. Open your terminal and navigate to your project directory.
  2. Run the following command to install the package:
npm install svelte-video-player
  1. Import the Svelte Video Player component in your Svelte file:
import VideoPlayer from "svelte-video-player";
  1. Use the Video Player component in your Svelte file:
<VideoPlayer source="video.mp4" controlsHeight="55px" color="#FF3E00" />
  1. Customize the component by providing props according to your requirements. Refer to the Prop name, Type, and Description in the Installation section for available options.

Summary

The Svelte Video Player is a versatile video player component for Svelte, Sapper, and legacy apps. It provides tabbable controls that respond to key presses and supports pausing previously playing instances when a new player is started. While fullscreen functionality is disabled on iPhone, it functions smoothly on both desktop and mobile browsers. The installation process is straightforward, making it easy to integrate into your Svelte projects.