Repository navigation
fix(sourcemap): keep only traced sources and names in module sourcemaps (#11270) - #11587
Merged
Merged
Conversation
…ps (#11270) Closes #11176 A transform that returns `{ mappings: '' }` or omits its map still shipped the module's earlier code in `sources`, `sourcesContent` and `names`. Module sourcemaps now keep only the sources and names that a traced token references, like Rollup's `traceMappings()`. The chunk-level collapse is unchanged. `this.getCombinedSourcemap()` now drops untraced sources and names too, like Rollup, so plugins can see this change. A load map that no transform has remapped still comes back as is. Names are marked inside the existing remap loop, so a map without names does no extra work. `generate` time on rome (1542 TS modules, `sourcemap: true`) is unchanged. The `combined_sourcemap_keeps_untransformed_load_map` test is based on the test of the same name in #11196. Co-authored-by: James <[email protected]>
sapphi-red
requested review from
IWANABETHATGUY,
hyfdev and
shulaoda
as code owners
November 9, 2026 07:18
🚀 Deploying Preview to Cloudflare 🚀Preview URL: https://fix-v12-empty-transform-source-rolldown-rs.voidzero-docs.workers.dev (commit 23ce1ec)This URL reflects your latest Preview deploymentPreview Deployments by commit
|
IWANABETHATGUY
approved these changes
Nov 9, 2026
Merged
sapphi-red
added a commit
that referenced
this pull request
Nov 9, 2026
## [1.2.18] - 2026-11-09 > [!TIP] > v1.2.17 was published to crates.io only. Its changes are released to npm in this version. ### 🐛 Bug Fixes - rolldown_plugin_vite_resolve: escape module names in generated error stubs (#11585) - sourcemap: keep only traced sources and names in module sourcemaps (#11270) (#11587) ### ⚙️ Miscellaneous Tasks - deps: update mimalloc-safe to 0.1.70 (#11593) - pick the Prepare Release target branch from the version (#11528) - run every OS on pushes to maintenance branches (#11523) - run CI on pushes to maintenance branches (#11519) - support patch releases from maintenance branches (#11514) Co-authored-by: sapphi-red <[email protected]>
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #11270 for v1.2