[GH-ISSUE #514] Clicking on links while there is a fragment in the url, appends url of link to fragment #295

Closed
opened 2026-04-08 16:51:48 +03:00 by zhus · 1 comment
Owner

Originally created by @al3xandros on GitHub (Dec 26, 2024).
Original GitHub issue: https://github.com/sigoden/dufs/issues/514

**Problem**

Bug: Clicking on a link that has a fragment / named anchor does not redirect to the link that I want.
url is: http://127.0.0.1:5000/#hello/folder/.

Expected: Redirection to the link clicked. Expected Url: http://127.0.0.1:5000/folder/#hello or http://127.0.0.1:5000/folder/ .

Configuration

Having directory listing on.

Log

Not needed

Screenshots/Media

Not needed

Environment Information

  • Dufs version: 0.43.0
  • OS: Linux / Debian 13
  • Browser: Firefox v133.0.3
Originally created by @al3xandros on GitHub (Dec 26, 2024). Original GitHub issue: https://github.com/sigoden/dufs/issues/514 `**Problem**` Bug: Clicking on a link that has a fragment / named anchor does not redirect to the link that I want. url is: `http://127.0.0.1:5000/#hello/folder/`. Expected: Redirection to the link clicked. Expected Url: `http://127.0.0.1:5000/folder/#hello` or `http://127.0.0.1:5000/folder/` . **Configuration** Having directory listing on. **Log** Not needed **Screenshots/Media** Not needed **Environment Information** - Dufs version: 0.43.0 - OS: Linux / Debian 13 - Browser: Firefox v133.0.3
zhus closed this issue 2026-04-08 16:51:49 +03:00
Author
Owner

@al3xandros commented on GitHub (Dec 26, 2024):

If the baseUrl function returned something like this: location.origin + location.pathname. I think the problem would be solved. Have not tested it

<!-- gh-comment-id:2563069094 --> @al3xandros commented on GitHub (Dec 26, 2024): If the [`baseUrl`](https://github.com/sigoden/dufs/blob/cbc620481dad734a4a0f970e447e2944317c3bf9/assets/index.js#L835) function returned something like this: `location.origin + location.pathname`. I think the problem would be solved. Have not tested it
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sigoden/dufs#295