adaptive-media-player
v1.0.6
Published
Akamai Adaptive Media Player NPM module
Downloads
1,312
Readme
adaptive-media-player-loader
This package facilitates the HTML5 Akamai Adaptive Media Player integration with projects using JavaScript module imports.
Installation
npm install adaptive-media-player --save-dev
Usage
import React, { useEffect } from 'react';
import AMP from 'adaptive-media-player'
function PlayerExample() {
useEffect(() => {
const config = {
autoplay: true,
media: { src: "https://example.com/video/bbb.mp4" }
}
AMP.create("customerApiKey", "#player", config)
});
return (
<div id="player"></div>
);
}