-
-
Notifications
You must be signed in to change notification settings - Fork 6.2k
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
fix: injectQuery
double encoding
#18246
Conversation
Co-authored-by: mykwillis <myk@mykwillis.com>
Run & review this pull request in StackBlitz Codeflow. |
// encode percents for consistent behavior with pathToFileURL | ||
// see #2614 for details |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment was irrelevant because pathToFileURL
was removed in #10449.
// encode percents for consistent behavior with pathToFileURL | ||
// see #2614 for details | ||
const resolvedUrl = new URL( | ||
url.replace(replacePercentageRE, '%25'), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It works by simply removing this url.replace
, but I think we can use splitFileAndPostfix
and avoid new URL
here.
/ecosystem-ci run |
📝 Ran ecosystem CI on
✅ astro, ladle, laravel, marko, nuxt, previewjs, quasar, qwik, rakkas, redwoodjs, storybook, sveltekit, unocss, vite-environment-examples, vite-plugin-pwa, vite-plugin-react, vite-plugin-react-swc, vite-plugin-svelte, vite-plugin-vue, vite-setup-catalogue, vitepress, vitest, vuepress |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks a lot cleaner!
Description
fixes #18244