Readable function hash and query order bug
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 6.2k
- Forks
- 468
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
first of all thanks for this helpful library!
Currently the hash part is appended after the query part, which does not work in browsers. They want the hash part immediately after the path part and before the query part. The solution is simple:
// Old
p.readable = function() {
...
t += uri.path(true);
if (uri._parts.query) {
...
}
t += URI.decodeQuery(uri.hash(), true);
return t;
}
// New
p.readable = function() {
...
t += uri.path(true);
t += URI.decodeQuery(uri.hash(), true); <---------- moved from below to here
if (uri._parts.query) {
...
}
return t;
}
Thanks!
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
Find the p.readable function shown in the issue and inspect how it assembles the path, hash, and query. Ensure the hash is emitted between the path and query, then verify that readable URLs have the expected browser-compatible ordering.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- web-dev
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100