# videojs-contrib-ads

> A framework that provides common functionality needed by video advertisement libraries working with video.js.

Latest version **7.5.2** (published 2024-05-17) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install videojs-contrib-ads
pnpm add videojs-contrib-ads
yarn add videojs-contrib-ads
bun add videojs-contrib-ads
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 7.5.2 |
| Published | 2024-05-17 |
| First published | 2013-11-19 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=8 |
| Dependencies | 1 |
| Unpacked size | 2.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Brightcove, Inc. |
| Maintainers | phale, ddashkevich, roman-bc, walterseymourbc, videojs-user, usmanonazim, mmcclure, misteroneill, misterben, lday, imbcmdth, hswaminathan, heff, gkatsev, gesinger, essk, dmlap, brandonocasey, awaldron, abarstow, incompl, bclwhitaker, jimbojw, forbesjo, violettemi, marguinbc, vdeshpande |
| Keywords | videojs, videojs-plugin |

## Links

- npm: https://www.npmjs.com/package/videojs-contrib-ads
- Repository: https://github.com/videojs/videojs-contrib-ads
- Homepage: https://github.com/videojs/videojs-contrib-ads#readme
- Issues: https://github.com/videojs/videojs-contrib-ads/issues
- npm.io page: https://npm.io/package/videojs-contrib-ads

## Dependencies (1)

- [global](https://npm.io/package/global.md) ^4.3.2

## 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

- 7.5.2 (latest) — 2024-05-17
- 6.8.0-0 (next) — 2021-03-29
- 5.2.0-1 (ssai) — 2018-01-22
- 5.1.1-1 (fix-notch) — 2017-11-01
- 5.0.4-0 (pre-5.0.4) — 2017-09-05
- 5.0.2-0 (fix-restore-snapshot-vjs-6) — 2017-07-03
- 4.2.7-vjs6qa.0 (vjs6qa) — 2017-05-09
- 4.2.4-2 (support-ie8) — 2017-02-23
- 4.2.4-1 (ad-type) — 2017-02-14
- 4.2.1-0 (qa) — 2017-01-17
- 4.1.7-0 (useMediaCuePoints) — 2016-12-23
- 4.0.0-0 (four-point-oh-prerelease) — 2016-10-05
- 2.2.2 (latest-2) — 2016-01-25
- 7.5.0 — 2024-03-19
- 7.4.0 — 2024-03-04
- … 111 more at https://npm.io/package/videojs-contrib-ads/versions

## README

![Contrib Ads: A Tool for Building Video.js Ad Plugins](logo.png)

[![Build Status](https://travis-ci.org/videojs/videojs-contrib-ads.svg?branch=main)](https://travis-ci.org/videojs/videojs-contrib-ads) [![Greenkeeper badge](https://badges.greenkeeper.io/videojs/videojs-contrib-ads.svg)](https://greenkeeper.io/)

`videojs-contrib-ads` provides common functionality needed by video advertisement libraries working with [video.js.](http://www.videojs.com/)
It takes care of a number of concerns for you, reducing the code you have to write for your ad plugin.

`videojs-contrib-ads` is not a stand-alone ad plugin. It is a library that is used by other ad plugins in order to fully support video.js. If you want to build an ad plugin, you've come to the right place. If you want to play ads in video.js without writing code, this is not the right project for you.

Maintenance Status: Stable

## Benefits

* Ad timeouts are implemented by default. If ads take too long to load, content automatically plays.
* Player state is automatically restored after ad playback, even if the ad played back in the content's video element.
* Content is automatically paused and a loading spinner is shown while preroll ads load.
* [Media events](https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Media_events) will fire as though ads don't exist. For more information, read the documentation on [Redispatch](http://videojs.github.io/videojs-contrib-ads/integrator/redispatch.html).
* Useful macros in ad server URLs are provided.
* Preroll checks automatically happen again when the video source changes.

## Documentation

[Documentation Index](http://videojs.github.io/videojs-contrib-ads/)

## Release History

A short list of features, fixes and changes for each release is available in [CHANGELOG.md](https://github.com/videojs/videojs-contrib-ads/blob/master/CHANGELOG.md).

## License

See [LICENSE](LICENSE).

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