- From: Ben Kelly <notifications@github.com>
- Date: Fri, 27 Apr 2018 14:34:50 -0700
- To: w3c/ServiceWorker <ServiceWorker@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Friday, 27 April 2018 21:35:12 UTC
If we wanted to provide a convenience for this use case maybe we could add a `RequestQueue` concept or something. Something like: ```javascript let c = await caches.open("foo"); // add something to a queue await c.enqueueRequest(FetchEvent.req); // pop the next item off the queue let req = await c.dequeueRequest(url); // drain the entire queue in one go let reqList = await c.drainRequests(url); ``` This would avoid the matching problem. All the posts match the same URL/vary combination. We just don't overwrite. Instead we queue the requests and don't have a response associated at all. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/w3c/ServiceWorker/issues/693#issuecomment-385100227
Received on Friday, 27 April 2018 21:35:12 UTC