Re: [whatwg/fetch] Add Async Stale While Revalidate Handling (#853)

annevk commented on this pull request.

I don't really like the name as fetches are already asynchronous. Perhaps we should simply use "stale-while-revalidate" as token name?

What about "must-revalidate" as @ziyunfei commented?

@mnot I'd like you to have a look too.

> @@ -4482,6 +4492,11 @@ Range Requests</cite>. [[HTTP-RANGE]] However, this is not widely supported by b
  <li><p>If <i>authentication-fetch flag</i> is set, then create an <a>authentication entry</a>
  for <var>request</var> and the given realm.
 
+ <li><p>If <i>revalidatingFlag</i> is set and <var>httpRequest</var>'s <a for=request>cache mode</a>
+ is "<code>async-stale-revalidated</code>" then asynchronously perform a

This needs a comma before then. "asynchronously" is not a thing, perhaps "in parallel"?

> @@ -4482,6 +4492,11 @@ Range Requests</cite>. [[HTTP-RANGE]] However, this is not widely supported by b
  <li><p>If <i>authentication-fetch flag</i> is set, then create an <a>authentication entry</a>
  for <var>request</var> and the given realm.
 
+ <li><p>If <i>revalidatingFlag</i> is set and <var>httpRequest</var>'s <a for=request>cache mode</a>
+ is "<code>async-stale-revalidated</code>" then asynchronously perform a
+ <a>HTTP-network-or-cache fetch</a> using <var>request</var> with <a for=request>cache mode</a>

This will bypass the service worker. Is that okay? It seems problematic that you can create a network request like that.

-- 
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/pull/853#pullrequestreview-188683406

Received on Wednesday, 2 January 2019 13:56:15 UTC