Skip to content

Require a hash in HTML spec URLs for <link rel=help> (and elsewhere) #63371

Open

Description

@zcorpan

There's inconsistency in how to link to the HTML spec in <link rel=help> in tests:

% git grep "html.spec.whatwg.org/multipage/#" | wc -l
    1073
% git grep "html.spec.whatwg.org/multipage/[^#]" | wc -l
    1363
% git grep "html.spec.whatwg.org/#" | wc -l
    1432

The first pattern causes a (scripted) redirect. The second pattern is not necessarily stable since things are sometimes moved around (the link should still work given the scripted redirect). The third option is shortest and has no redirect.

My preference would be to always link to the single-page version, and add a lint check for this. This makes it clear for contributors and avoids review time about which URL to use.

Edit: per discussion below, instead only require a hash in the lint, and fix currently broken/old links.

Activity

  1. added 2 commits that reference this issue on Oct 7, 2026
    2b384c6
    28b4902
  2. zcorpan commented on Oct 7, 2026

    @zcorpan
    MemberAuthor

    Rewrite: #63375
    Lint check, to be landed some time later: #63377

  3. domfarolino commented on Oct 8, 2026

    @domfarolino
    Member

    Wait why is https://html.spec.whatwg.org/C/#navigate bad? Scripted redirects help SO much when you're on the go, or investigating things on crappy networks on a mobile device. Actually, we should standardize everything to that!

  4. zcorpan commented on Oct 8, 2026

    @zcorpan
    MemberAuthor

    With C it means test writers need to always change the URL copied from the spec since it redirects somewhere else.

    Maybe the "I prefer multipage on this device" use case could be solved with a cookie-based redirect in the spec, so you always go the multipage while the cookie is present?

  5. domfarolino commented on Oct 8, 2026

    @domfarolino
    Member

    That's one option, but I'm still struggling to see the motivation for this in the first place.

    It seems like /C/#foo and /multipage/#foo are the same. Is it an issue if test authors link to these URLs (or even fully-qualified multipage URLs)?

  6. zcorpan commented on Oct 8, 2026

    @zcorpan
    MemberAuthor

    Mostly consistency and that a multipage link without a hash can't easily be translated to the single-page equivalent. Maybe "require a hash" is sufficient?

    There are also mistakes like multipage/multipage/ and multipage/C, but those can be fixed.

  7. domfarolino commented on Oct 8, 2026

    @domfarolino
    Member

    I think I'd personally prefer "require a hash" since that helps normalize definitions in the most useful way, without favoring one page variant over an other. All of this is just personal preference though.

  8. zcorpan commented on Oct 8, 2026

    @zcorpan
    MemberAuthor

    OK, let's do that instead. Converting all links to single-page and trying to land a lint while new changes are coming in is non-trivial churn. Thanks!

  9. changed the title [-]Standardize on single-page HTML for `<link rel=help>`[/-] [+]Require a hash in HTML spec URLs for `<link rel=help>` (and elsewhere)[/+] on Oct 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions