Skip to content

Conversation

bgw
Copy link
Member

@bgw bgw commented Sep 30, 2025

We have a mix of some code that treats turbopack:/// urls as proper URLs and attempts to percent encode/decode them, and some code that assumes it's just a dumb prefixed file path.

They look and smell like URLs, and the source map spec says they should be URLs, so let's treat them as actual URLs everywhere.

TODO

  • Replace remaining callsites of the urlencoding crate with percent-encoding so that we're only using one encoding library.
  • Make sure I didn't horribly break everything.

@ijjk ijjk added created-by: Turbopack team PRs by the Turbopack team. Turbopack Related to Turbopack with Next.js. type: next labels Sep 30, 2025
Copy link
Member Author

bgw commented Sep 30, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@bgw bgw changed the title Turbopack: Always encode turbopack:///[fs]/ urls as valid URLs [DRAFT] Turbopack: Always encode turbopack:///[fs]/ urls as valid URLs Sep 30, 2025
Copy link

codspeed-hq bot commented Sep 30, 2025

CodSpeed Instrumentation Performance Report

Merging #84362 will not alter performance

Comparing bgw/turbopack-urls-are-urls (5f6f616) with canary (b90559c)

Summary

✅ 17 untouched
⏩ 3 skipped1

Footnotes

  1. 3 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
created-by: Turbopack team PRs by the Turbopack team. Turbopack Related to Turbopack with Next.js. type: next
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants