Re: [whatwg/fetch] Define the "Preload Cache" (#590)

After the TPAC conversation, this is the rough definition of preload cache I propose:

- A document has a store of preloaded responses
- A preload link (tag or header) fetches and keeps the response in that store (regardless of cache or errors)
- The next subsequent fetch that matches that response will receive that response and remove it from store (though it might still be kept in other caches, like the resource/memory cache or HTTP cache)
- The `load` event clears the store and reports what preloads were unused

This definition totally separates preloads from the different resource caches or any type-specific behavior, though implementations are welcome to further optimize.

The tests will ensure that there are no *extra* network fetches, but they will allow implementations to have *less* fetches.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/issues/590#issuecomment-951575743

Received on Tuesday, 26 October 2021 05:31:50 UTC