Searches including hashes (#) fail when linked to
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 22.2k
- Forks
- 1.9k
- PR merge metrics
- PR metrics pending
Description
Problem
I have tags in my pages and am linking them to searches. If I link to ?search=blog then pages with #blog don't show up. When I search manually for #blog I get the correct results and the URL is search#blog. The issue is that when I link to search#blog, the url gets replaced with search=undefined
Steps
- Search for something with a hash at the start
- reload the page and watch the search change to undefined
Possible Solution(s)
No response
Notes
No response
Version
mdbook v0.4.51
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue using a linked search for a term beginning with #, then reload the page and compare it with a manually performed search. Trace the search URL handling from the relevant search entry point; done means linked hash searches retain their query instead of becoming undefined and continue returning the expected pages.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- search
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100