If websites use raw audio
or video
tags, you will see some basic controls for them, but usually, they do not include the control for changing the playback speed.
Since I usually want to playback audio or videos faster, I created a bookmarklet to change the playback speed for all elements.
This will open a small dialog where you can choose the speed:
To use, it, just add a new bookmark, give it a speaking name and copy the following code into the URL field:
javascript:(() => {
var speed = prompt("How fast should it be? : ", "1.5");
if(speed) {
document.querySelectorAll('audio').forEach((player) => { player.playbackRate = speed });
document.querySelectorAll('video').forEach((player) => { player.playbackRate = speed });
}
})()
Posted by Judith Roth to Judith's Dev Notes (2022-04-05 11:28)