Skip to content

Commit

Permalink
revise
Browse files Browse the repository at this point in the history
  • Loading branch information
noamr committed Nov 4, 2021
1 parent 0613515 commit 5c19df6
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions fetch.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1828,6 +1828,9 @@ otherwise, it is unset.
<a for=request>timing allow failed flag</a> are used as bookkeeping details by the
<a for=/>fetch</a> algorithm.

<p>A <a for=/>request</a> has an associated boolean <dfn for=request>allow preloads</dfn>.
Unless stated otherwise it is true.

<hr>

<p>A <dfn export>subresource request</dfn> is a <a for=/>request</a>
Expand Down Expand Up @@ -3811,6 +3814,44 @@ 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>Origin</code>`, `<code>User-Agent</code>`, `<code>Referer</code>`,
or `<code>Cache-Control</code>`, set <var>hasCustomHeaders</var> to true.

<li>
<p>If all of the following conditions are true:</p>

<ul class=brief>
<li><p><var>request</var>'s <a for=request>allow preloads</a> is true

<li><p><var>hasCustomHeaders</var> is false

<li><p><var>request</var>'s <a for=request>window</a> is not null

<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>Let <var>preloadedResponse</var> be the result of invoking
<span>consume a preloaded resource</span> for <var>request</var>'s <a for=request>window</a>,
with <var>request</var>'s <a for=request>URL</a>, <var>request</var>'s <a for=request>origin</a>,
<var>request</var>'s <a for=request>destination</a>, <var>request</var>'s
<a for=request>mode</a>, <var>request</var>'s <a for=request>credentials mode</a>, and
<var>request</var>'s <a for=request>integrity metadata</a>.

<li><p>If <var>preloadedResponse</var> is not null, then run <a>fetch finale</a> with
<var>preloadedResponse</var> and <var>fetchParams</var>, and return.
</ol>
</li>



<li>
<p>If <var>request</var>'s <a for=request>policy container</a> is "<code>client</code>", then:

Expand Down

0 comments on commit 5c19df6

Please sign in to comment.