Re: [w3c/ServiceWorker] async waitUntil() does not allow extension on final promise resolution? (#1039)

> you queue a **microtask** upon fulfillment and decrease from that microtask

I think this would satisfy Ben's mental model. This would even work for all sequences:
```js
e.waitUntil(p);
p.then(_ => e.waitUntil(q));
p.then(_ => e.waitUntil(r));

p.then(_ => e.waitUntil(q));
e.waitUntil(p);
p.then(_ => e.waitUntil(r));

p.then(_ => e.waitUntil(q));
p.then(_ => e.waitUntil(r));
e.waitUntil(p);
```

I'm happy with this solution.

-- 
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/1039#issuecomment-272395861

Received on Friday, 13 January 2017 09:14:37 UTC