hls.js icon indicating copy to clipboard operation
hls.js copied to clipboard

Can I directly load the content of the m3u8 file instead of requesting the m3u8 url to get the content?

Open theajack opened this issue 4 months ago • 3 comments

What do you want to do with Hls.js?

Can I directly load the content of the m3u8 file instead of requesting the m3u8 url to get the content?

What have you tried so far?

No relevant API found in the documentation

theajack avatar Feb 07 '24 07:02 theajack

Officially, no. Unofficially, try triggering MANIFEST_LOADED.

robwalch avatar Feb 07 '24 12:02 robwalch

Officially, no. Unofficially, try triggering MANIFEST_LOADED.

@robwalch Thanks, I'll give it a try

theajack avatar Feb 07 '24 16:02 theajack

The other options are to create a custom loader or use xhrSetup to capture a request for a "custom URL" and return the content via a fake response (loadSource('custom://replace-with-network-filter')) .

You could also encode the content in a data URL and pass that to loadSource.

robwalch avatar Feb 07 '24 18:02 robwalch