# Custom Header Links: links reload Discourse

**URL:** https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907
**Category:** Support
**Created:** [09.Апрель.2019 21:28:41 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907 "2019-04-09T21:28:41Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![jack2](https://avatars.discourse-cdn.com/v4/letter/j/ac91a4/32.png) [@jack2](https://meta.discourse.org/u/jack2)
#### Post date: [09.Апрель.2019 21:28:41 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/1 "2019-04-09T21:28:41Z")

</div>

I’m using the Custom Header Links component and I’m getting this strange behavior:

- In my prod instance, clicking a header link reloads Discourse entirely to the target page.
- In my dev instance (without docker), clicking a header link transitions smoothly to the target page without reloading Discourse.

I noticed that:

- In my prod instance, `<a>` tags have a `data-auto-route="true"` attribute.
- In my dev instance, `<a>` tags don’t have this attribute.

It seems the same kind of problem happened in the past (see [here](https://meta.discourse.org/t/reload-page-body-when-clicking-a-link-in-a-custom-header/90543)), before the official header components were released.

---

<div class="post-metadata">

### Author: ![syl](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/syl/32/98883_2.png) [@syl](https://meta.discourse.org/u/syl)
#### Post date: [26.Апрель.2019 22:54:27 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/2 "2019-04-26T22:54:27Z")

</div>

I created a fork to fix this issue: [GitHub - sylque/discourse-custom-header-links2: Same as the official discourse-custom-header-links, but with links moved to the hamburger menu instead of being hidden · GitHub](https://github.com/sylque/discourse-custom-header-links).

---

<div class="post-metadata">

### Author: ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)
#### Post date: [26.Апрель.2019 23:02:21 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/3 "2019-04-26T23:02:21Z")

</div>

Reverting the change from @j.jaffeux breaks internal links in a different way. I wouldn’t use a forked plugin - it just means when this gets fixed for real you won’t receive the changes automatically.

The commit in question:

[https://github.com/discourse/discourse-custom-header-links/commit/bfda9d3b50bd8e027024b62aa0b7e68611248073](https://github.com/discourse/discourse-custom-header-links/commit/bfda9d3b50bd8e027024b62aa0b7e68611248073)

---

<div class="post-metadata">

### Author: ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)
#### Post date: [29.Апрель.2019 13:45:53 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/4 "2019-04-29T13:45:53Z")

</div>

Any ideas @j.jaffeux?

---

<div class="post-metadata">

### Author: ![Johani](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/johani/32/176920_2.png) [@Johani](https://meta.discourse.org/u/Johani)
#### Post date: [04.Май.2019 14:51:05 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/5 "2019-05-04T14:51:05Z")

</div>

This is [fixed in the official component](https://github.com/discourse/discourse-custom-header-links/commit/175a027582eac0b95803b3675ea37faf527ae68c), internal links will no longer cause a full page reload.

Thanks for reporting the issue @jack2 👍

---

<div class="post-metadata">

### Author: ![Johani](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/johani/32/176920_2.png) [@Johani](https://meta.discourse.org/u/Johani)
#### Post date: [04.Май.2019 14:51:16 UTC](https://meta.discourse.org/t/custom-header-links-links-reload-discourse/113907/6 "2019-05-04T14:51:16Z")

</div>


