videojs-video-element

1.1.2 • Public • Published

<videojs-video>

NPM Version NPM Downloads jsDelivr hits (npm) npm bundle size

A custom element for Video.js with an API that matches the <video> API.

Example (CodeSandbox)

<script type="module" src="https://cdn.jsdelivr.net/npm/videojs-video-element@1.0/+esm"></script>
<videojs-video controls src="https://stream.mux.com/O6LdRc0112FEJXH00bGsN9Q31yu5EIVHTgjTKRkKtEq1k/high.mp4"></videojs-video>

Install

First install the NPM package:

npm install videojs-video-element

Import in your app javascript (e.g. src/App.js):

import 'videojs-video-element';

Optionally, you can load the script directly from a CDN using JSDelivr:

<script type="module" src="https://cdn.jsdelivr.net/npm/videojs-video-element@1.0/+esm"></script>

This will register the custom elements with the browser so they can be used as HTML.

Related

Dependencies (2)

Dev Dependencies (1)

Package Sidebar

Install

npm i videojs-video-element

Weekly Downloads

89

Version

1.1.2

License

MIT

Unpacked Size

11.8 kB

Total Files

3

Last publish

Collaborators

  • luwes