How can I use howler js and update the progress bar as the audio plays?
I assume I use either pos
or seek
however I can't seem to get it working.
Can I create a on
event listener to change every time the position changes?
Progress bar HTML:
<progress id="progress_bar" value="0.0" max="1.0" style="-webkit-appearance: none; appearance: none; height: 48px; float: left;"></progress>
Howler js:
on ('update_progress', function() {
document.getElementById('progress_bar').value = audio.pos();
}),
and then how can I update the position of the audio if the progress bar is pressed. I think I might actually be better served using an input range in that case.
on("mute", function());
but it doesn't seem to work. – Unreason