Skip to content

Commit e559864

Browse files
committed
Define link processing for prefetch
Prefetch is simply a fetch with `prefetch-src` CSP and no post-processing of the resource. Closes #5229
1 parent 5be9e62 commit e559864

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

source

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25930,6 +25930,32 @@ document.body.appendChild(wbr);</code></pre>
2593025930
<p>There is no default type for resources given by the <code data-x="rel-prefetch">prefetch</code>
2593125931
keyword.</p>
2593225932

25933+
<p>The <span>fetch and process the linked resource</span> algorithm for <code
25934+
data-x="rel-prefetch">prefetch</code> links, given a <code>link</code> element
25935+
<var>el</var>, is as follows:</p>
25936+
25937+
<ol>
25938+
<li><p>If <var>el</var>'s <code data-x="attr-link-href">href</code> attribute's value is the
25939+
empty string, then return.</p></li>
25940+
25941+
<li><p>Let <var>options</var> be the result of <span data-x="create link options from
25942+
element">creating link options</span> from <var>el</var>.</p></li>
25943+
25944+
<li><p>Let <var>request</var> be the result of <span data-x="create a link request">creating a
25945+
link request</span> given <var>options</var>.</p></li>
25946+
25947+
<li><p>Set <var>request</var>'s <span data-x="concept-request-destination">destination</span>
25948+
to "<code data-x="">prefetch</code>".</p></li>
25949+
25950+
<li><p>Set <var>request</var>'s <span data-x="concept-request-initiator">initiator</span>
25951+
to "<code data-x="">prefetch</code>".</p></li>
25952+
25953+
<li><p><span data-x="concept-fetch">Fetch</span> <var>request</var>.</p></li>
25954+
</ol>
25955+
25956+
<p>The <span>process a link header</span> steps for this type of linked resource are to do
25957+
nothing.</p>
25958+
2593325959

2593425960
<h5>Link type "<dfn for="link/rel" attr-value><code
2593525961
data-x="rel-preload">preload</code></dfn>"</h5>

0 commit comments

Comments
 (0)