Post #1381718
2026-04-01 08:21 UTC
@trygve_lie @gundersen I'd have the image file, up to the first layer, encoded in the hash of the URL. The service worker would intercept the request, and immediately serve the hashed part back to the page, but leave the stream open, meanwhile, it'd make a range request for the rest of the image file, and pipe it into the stream.
Replies (2)
-
@jaffathecake@mastodon.social 2026-04-01 09:04
@trygve_lie @gundersen this same pattern would work with all progressive formats
-
@trygve_lie@mastodon.social 2026-04-01 14:53
@jaffathecake Right. My thought was to use OffScreenCanvas and related APIs to get what one need from blob data in the ServiceWorker. But, that excludes AVIF due to those APIs. @gundersen