Re: [slightlyoff/ServiceWorker] Eliminating SW startup latency for common case (#920)

I captured @slightlyoff in the pub and got him to answer the questions on his proposal. Here they are (from memory):

> Is the preflight opt-in? If so, by what mechanism?

Maybe/probably. No mechanism yet. Maybe it should only be for certain urls.

> Does the preflight happen for every request, or just navigations?

Just navigations.

> What type is e.preflightResponse is it a Response?
> What happens if the fetch event can fire before e.preflightResponse is ready?

`e.preflightResponse` should be a promise, therefore the fetch event isn't delayed.

> If I do not use the preflight, what happens to it? Eg what if it's a 3gb video?

Unsure.

> If my SW does fetch(event.request), is that an additional request? That will be the case for most existing SWs
> If my SW does fetch(event.request.url), is that an additional request?

It will make an extra request.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/slightlyoff/ServiceWorker/issues/920#issuecomment-230465216

Received on Tuesday, 5 July 2016 12:33:40 UTC