Re: [whatwg/fetch] Integration with preload (PR #1342)

@annevk commented on this pull request.



> +
+   <li><p><var>request</var>'s <a for=request>method</a> is `<code>GET</code>`
+  </ul>
+
+  <p>then perform the following steps:
+
+  <ol>
+   <li><p>Assert: <var>request</var>'s <a for=request>origin</a> is <var>request</var>'s
+   <a for=request>client</a>'s <a for="environment settings object">origin</a>.
+
+   <li><p>Let <var>onPreloadedResponseAvailable</var> be to an algorithm that runs the following
+   step <a>in parallel</a> given <a for=/>response</a> <var>response</var>: run
+   <a>fetch finale</a> given <var>response</var> and <var>fetchParams</var>.
+
+   <li><p>Let <var>foundPreloadedResource</var> be the result of invoking
+   <span>consume a preloaded resource</span> for <var>req</var>'s <a for=request>window</a>,

This should use `<a>`.

> @@ -3811,6 +3814,54 @@ the request.
  <var>request</var>'s <a for=request>origin</a> to  <var>request</var>'s <a for=request>client</a>'s
  <a for="environment settings object">origin</a>.
 
+ <li><p>Let <var>hasCustomHeaders</var> be false.
+
+ <li><p><a for=list>For each</a> <var>header</var> in <var>request</var>'s
+ <a for=request>header list</a>, if <var>header</var>'s <a for=header>name</a> is
+ not `<code>If-Modified-Since</code>`, `<code>If-None-Match</code>`, `<code>If-Unmodified-Since</code>`,
+ `<code>If-Match</code>`, `<code>User-Agent</code>`, or `<code>Cache-Control</code>`, set
+ <var>hasCustomHeaders</var> to true.

I had misread it, but it also seems the requirement is different now. Any author-defined headers triggers it now. But doesn't that also apply to `XMLHttpRequest`?

-- 
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/1342#pullrequestreview-825192754

Received on Tuesday, 7 December 2021 12:15:53 UTC