-
Notifications
You must be signed in to change notification settings - Fork 54
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
Please encode " | " as %7C #233
Comments
Looking at the source it would seem that ufo has done this for a long time already for some reason. As a means to, undo what encodeURI apparently does? Somehow later the replacement of the brackets have been removed but the undoing of the pipe encoding has stayed for whatever reason? Afaik; the pipe should be encoded as %7c and not decoded to @pi0 I know it's a long stretch but any shot at remembering (2020 😅) why we're doing it like this? |
I'd have no issue opening a PR to remove said decoding - but as the tests are seemingly not even testing for anything related to |
I think an additional question related to this posed here #240 opens up a valid consideration; should ufo not use encodeURIComponent? |
Environment
N/A
Reproduction
According to the code below, there is no encoding for vertical bar ( | ).
https://github.com/unjs/ufo/blob/cda2af90fc4aaaa2133d8b0529570ee8955338a6/src/encoding.ts#L59C1-L71C2
Describe the bug
According to the code below, there is no encoding for vertical bar ( | ).
https://github.com/unjs/ufo/blob/cda2af90fc4aaaa2133d8b0529570ee8955338a6/src/encoding.ts#L59C1-L71C2
Additional context
No response
Logs
No response
The text was updated successfully, but these errors were encountered: