Skip to content

In-page anchors do not work on first page load #3261

Closed
@CGamesPlay

Description

@CGamesPlay

Hello! Apologies if this has been reported elsewhere, I scanned the recent open/closed issues and didn't spot anything.

Steps to reproduce:

  1. Open https://reactjs.org/docs/react-component.html
  2. Click on the first link reading render().

Expected behavior: page has scrolled so that the documentation for render is visible.
Actual behavior: most of the time, nothing happens.

Sometimes a second, third, or tenth click will make it work, and sometimes the first click does correctly scroll. I encounter this (from googling the name of a lifecycle method, for instance) frequently enough that it's becoming a hassle to use the React docs. This affects all pages, including the blog.

Using Chrome Version 85.0.4183.102 (Official Build) (64-bit). I'm unable to reproduce the problem in Safari.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions