-
-
Notifications
You must be signed in to change notification settings - Fork 10.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to do anchor aka "hash" links? #1454
Comments
+1 |
I can't remember if I closed this because I found a duplicate issue or if I actually figured out how to do it. Anybody know the status of this feature? |
+1 I use history locations only and want the original behavior for hashlinks back! |
how do you do this? |
+1 |
@darobin Can you please provide details about how did you fix the normal anchor links? Using |
@pratyushmittal I haven't checked but I believe in my case it is also still re-rendering. After all, it does change the route. But it works: the browser navigates to the hash, which is the desired behaviour. In my case the re-render isn't an issue, the route only affects topmost components, the rest won't see the change. |
I do see as problematic that the re-render is triggered, since navigating within sections on the same page then causes an unnecessary performance overhead. Is there any supported way to prevent re-rendering while using named anchors to sections on the same page? |
Any progress on this subject? I wonder why the issue is closed. React is still re-rendering pages. |
As a workaround, I think you can respond to |
Any progress here? If there is duplicate issue, can anyone please provide URL of that issue? |
Say I have some
<div id="my-section"> ... </div>
, how do I link to this section of the page? This is a really useful feature of the web.The text was updated successfully, but these errors were encountered: