rust-lang / rust-lang/mdBook

"prefetch" not allowed in "<a>"?

Open
#2,879 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-HTML
Dominant language
Rust
Stars
22.2k
Forks
1.9k
PR merge metrics
PR metrics pending

Description

This has been added in #2168.

I'm really not an expert in this, but I've been reading https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/rel, which mentions that prefetch is Not allowed in anything except <link>.

The same page says about rel="next":

When included in a <link>, browsers may assume that document will be fetched next, and treat it as a resource hint.

So I guess it would be good to add <link rel="next" ...>, or maybe <link rel="next prefetch" ...>, but I'm not sure whether latter makes a difference.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Review the change introduced in #2168 and compare the generated link markup with the MDN guidance on rel attributes. Locate the mdBook output path responsible for this relation, then add or update coverage for the generated HTML and verify that the intended link element and rel values are emitted.

Written by the indexing model from the issue text.

Assessment

Tech stack
html, rust
Domain
documentation
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.