# media-playlist

> Play through a set of video and audio elements.

Latest version **0.1.1** (published 2023-02-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install media-playlist
pnpm add media-playlist
yarn add media-playlist
bun add media-playlist
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2023-02-03 |
| First published | 2020-10-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 7.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 17 |
| Author | @heff |
| Maintainers | heff |
| Keywords | playlist, media, player, audio, video |

## Links

- npm: https://www.npmjs.com/package/media-playlist
- Repository: https://github.com/muxinc/media-playlist
- npm.io page: https://npm.io/package/media-playlist

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 0.1.1 (latest) — 2023-02-03
- 0.1.0 — 2022-06-12
- 0.0.3 — 2020-10-27
- 0.0.2 — 2020-10-27

## README

# `<media-playlist>`

A custom element for playing through a set of audio and/or video elements.

## Example

```html
<html>
<head>
  <script type="module" src="https://unpkg.com/media-playlist@0.1"></script>
</head>
<body>

<media-playlist loop>
  <media-playlist-item type="video" src="" controls></media-playlist-item>
  <media-playlist-item type="audio" src="" controls></media-playlist-item>
  <media-playlist-item type="video" src="" controls></media-playlist-item>
</media-playlist>

</body>
</html>
```

## Installing

`<media-playlist>` is packaged as a javascript module (es6) only, which is supported by all evergreen browsers and Node v12+.

### Loading into your HTML using `<script>`

Note the `type="module"`, that's important.

> Modules are always loaded asynchronously by the browser, so it's ok to load them in the head :thumbsup:, and best for registering web components quickly.

```html
<head>
  <script type="module" src="https://unpkg.com/media-playlist@0.1"></script>
</head>
```

### Adding to your app via `npm`

```bash
npm install media-playlist --save
```
Or yarn
```bash
yarn add media-playlist
```

Include in your app javascript (e.g. src/App.js)
```js
import 'media-playlist';
```
This will register the custom elements with the browser so they can be used as HTML.

---
_Source: https://npm.io/package/media-playlist · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
