@uln/hls 0.3.0
pnpm add @uln/hls

Examples

exampleplaysUI
simplestHLSReact
single-video/reactHLSReact
single-video/vanillaHLSDOM
clip-cardHLS MP4React
carousel/reactHLS MP4React
carousel/vanillaHLS MP4DOM
hover-gridHLS MP4React
loading-screenHLSReact
film-pageHLSReact
custom-controlsHLSReact
background-loopHLS MP4React
playlistHLSReact

Benchmarks

uln uln-0.3.0 hlsjs

fiber: 50 Mbps, 10 ms

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln1510.00100690%1.085.344
uln-0.3.03350.00102490%1.083.0306
hlsjs2330.00100690%1.082.5341

cable: 15 Mbps, 20 ms

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln3970.00100790%1.067.432
uln-0.3.07380.00102490%1.067.9279
hlsjs4470.00100590%1.067.4311

4g: 6 Mbps, 50 ms

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln9140.006840%1.028.732
uln-0.3.015740.007010%1.027.5250
hlsjs9740.006820%1.028.7261

slow: 1.6 Mbps, 150 ms

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln32290.003600%0.07.142
uln-0.3.055840.003810%1.07.1183
hlsjs32770.003600%0.07.1188

drop: 15 Mbps, falling to 1.2 Mbps at 0:12, back at 0:30

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln4230.0094281%2.039.839
uln-0.3.07500.0089271%2.040.9256
hlsjs4480.0086971%2.040.2278

fluctuating: 8 and 2 Mbps alternating every 6 s

first frame (ms)stallsstalled (ms)mean height showntime at 1080pswitchesdownloaded (MB)main-thread script (ms)
uln6960.006830%1.027.136
uln-0.3.012660.006630%3.027.8247
hlsjs7770.006820%1.026.4262

seek: three seeks into unbuffered media, 15 Mbps

seek to playing (ms)stallsdownloaded (MB)
uln8150.036.2
uln-0.3.033130.050.2
hlsjs33760.050.1

warm start: 4 s on the page before the tap, 6 Mbps (preload for @uln/hls; hls.js buffers once attached)

first frame after tap (ms)fetched before the tap (MB)mean height shown
uln271.0683
uln-0.3.014321.0701
hlsjs1762.2684
Method

Chromium (headless), 3 runs each, medians. 40 s of playback per run on 2 minutes of Big Buck Bunny (360p 0.8 Mbps, 540p 1.6, 720p 3, 1080p 6; AAC audio apart; 4 s segments) in a 1920×1080 element. Generated by pnpm bench on 2026-10-26.

Contenders: uln is this package; uln-0.3.0 is the release before it, which played through hls.js with its own settings; hlsjs is hls.js 1.7.3 with its defaults.

Engine download, minified and gzipped: uln 9.1 KB, hls.js 183.6 KB.

bench/run.ts · latest.json

Media
film60 s HLS, 4 s fMP4 segments, H.264 360p 0.8 / 540p 1.6 / 720p 3 / 1080p 6 Mbps, AAC 128 kbps apart
clip6 s MP4 from 0:42, 540p, silent
servingstatic files on Workers static assets, no Worker code