Skip to content

dtubenetwork/hlsjs-ipfs-loader

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

hlsjs-ipfs-loader

A js-ipfs loader for the hls.js JavaScript HLS client

Building

To build hlsjs-ipfs-loader, make sure you have the latest version of npm installed. Then simply run the following commands from the hlsjs-ipfs-loader project root:

npm install
npm run build

This will write a self-contained JS bundle to dist/index.js

Browser example

Include script tags for HLS.js, js-ipfs and hlsjs-ipfs-loader:

<script src="https://unpkg.com/ipfs/dist/index.js"></script>
<script src="https://cdn.jsdelivr.net/npm/hls.js@latest"></script>
<script src="dist/index.js"></script>

After including these dependencies, add your own script that hooks everything up. Please see this example for more details.

NOTE: Chrome's strict security policies block the example from running locally, so you will either have to spin up a local web server to host it from (unless you want to explicitly fiddle with the policies), or run it in Firefox where this restriction currently doesn't exist.

About

A js-ipfs loader for the hls.js JavaScript HLS client

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%