This project contains code samples demonstrating how to build, package, and integrate with the Amazon IVS Player Web SDK. You can find the Web SDK API reference and documentation here.
- Node 12+
- NPM 6+
- A browser which meets the IVS web player requirements
- Locally clone this repository.
- Install dependencies:
npm install
- Build and host using webpack-dev-server:
npm start
- Alternatively, you can just build with
npm run bundle
. Thedist/
folder can then be independently hosted.
- Alternatively, you can just build with
- Navigate to the index page and select a demo.
- Once in the demo, open the developer tools to see relevant logs.
- Cloud Player Demo - Demonstrates how to instantiate a player using our cloud-hosted assets. Webpack is used here to transpile TypeScript.
- How to load from NPM - Demonstrates how to create a player using the NPM package and Webpack.
- Basic VideoJS Tech demo - A basic integration with the IVS player VideoJS tech.
- Pure JavaScript Codepen - A demo player built using pure JavaScript.
- Webpack build configuration - Demonstrates how to make player assets available via Webpack.
Please see each sample for detailed code comments.
Try out this repo in Repl.it. You can build, run, and experiment with our code without having to set it up yourself.
- Visit https://repl.it/github/aws-samples/amazon-ivs-player-web-sample and sign up for an account
- Leave the default repl.it configuration (select language: Node.js, configure the run button:
npm start
) and click "Done" - Click the "Run" button
- Wait for
npm install
andnpm start
to complete. You should seeCompiled successfully
in the console when done - Reload the page and browse the live samples in the top right window
- 1080p30 - https://fcc3ddae59ed.us-west-2.playback.live-video.net/api/video/v1/us-west-2.893648527354.channel.DmumNckWFTqz.m3u8
- Square Video - https://fcc3ddae59ed.us-west-2.playback.live-video.net/api/video/v1/us-west-2.893648527354.channel.XFAcAcypUxQm.m3u8
- Vertical Video - https://fcc3ddae59ed.us-west-2.playback.live-video.net/api/video/v1/us-west-2.893648527354.channel.YtnrVcQbttF0.m3u8
- Quiz - https://fcc3ddae59ed.us-west-2.playback.live-video.net/api/video/v1/us-west-2.893648527354.channel.xhP3ExfcX8ON.m3u8
- VOD - https://d6hwdeiig07o4.cloudfront.net/ivs/956482054022/cTo5UpKS07do/2020-07-13T22-54-42.188Z/OgRXMLtq8M11/media/hls/master.m3u8
This project is licensed under the MIT-0 License. See the LICENSE file.