Skip to content

Instantly share code, notes, and snippets.

@ssaguiar
ssaguiar / gist:bf5d1f80fe630f46844f551c810ca5c8
Created August 29, 2018 20:39
Simple 20 channels mosaic using hls.js
<div id="carousel"><video id="video01" width="320" height="180" controls muted></video><div id="buttonscontainer"><p>Channel Test01</p><button type="button" onclick="alert('Button Channel 1')"><i class="fa fa-sync-alt" aria-hidden="true"></i> Restart</button></div></div>
<script>
if(Hls.isSupported()) {
var video01 = document.getElementById('video01');
video01.setAttribute("controls","controls")
var hls = new Hls();
hls.loadSource('http://0.0.0.0/live/playlist.m3u8');
@ssaguiar
ssaguiar / 0_reuse_code.js
Last active August 29, 2015 14:17
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console