Skip to content

feat(alias,auto-install,beep,esm-shim,multi-entry,run,terser): support rollup 5 - #2037

Merged
lukastaegert merged 7 commits into
masterfrom
simple-rollup-5-updates
Dec 4, 2026
Merged

lukastaegert merged 7 commits into
masterfrom
simple-rollup-5-updates

Conversation

@lukastaegert

@lukastaegert lukastaegert commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

Rollup Plugins: 27 plugins

alias, auto-install, beep, esm-shim, multi-entry, run, terser

This PR contains:

  • feature
  • bugfix
  • refactor
  • documentation
  • other

Are tests included?

  • yes
  • no

Breaking Changes?

  • yes
  • no

List any relevant issue numbers:

Description

Prepare the plugins that only need a peer dependency range extension for Rollup 5. Each plugin now accepts rollup@^5.0.0, tests against rollup@5.0.0-3 through the new rollup-next catalog, and includes the Rollup 5 test and snapshot adaptations it needs.

This is intended to trigger a minor release for each of the 7 updated plugins.

generated with AI

@lukastaegert
lukastaegert marked this pull request as ready for review November 2, 2026 16:31
Copilot AI balanced review requested due to automatic review settings November 2, 2026 16:31
@greptile-apps

greptile-apps Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Confidence Score: 5/5RetriggerView in Greptile

[Medium impact] The PR appears safe to merge; no actionable issues remain.

Reviews (12) · Last reviewed commit: "feat(terser): support rollup 5" · Reviewed by Greptile

Comment thread pnpm-workspace.yaml Resolved

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The Rollup 5 upgrade requires Node >=22.22.0 while CI still runs Node 20, and the updated HTML snapshot no longer verifies exclusion of non-entry chunks.

2 open issues
1 file not reviewed
  • pnpm-lock.yaml: Generated file
What changed in this PR

Prepares 29 Rollup plugins and utilities for Rollup 5 by updating dependency declarations and compatibility tests. json and wasm remain excluded because they require separate source changes.

Changes:

  • Adds Rollup 5 peer support and a shared rollup-next development catalog.
  • Updates test expectations and snapshots, adds build smoke tests, and adjusts Node type dependencies.
  • Isolates auto-install’s pnpm fixtures and checks that installs leave the root lockfile unchanged.
File Description
pnpm-workspace.yaml Defines the Rollup 5 development catalog.
pnpm-lock.yaml Locks Rollup 5 and updated dependency resolutions.
packages/​yaml/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​virtual/​test/​types.test.js Includes Node types in type tests.
packages/​virtual/​test/​rollup-build.test.js Adds a virtual-module build smoke test.
packages/​virtual/​package.json Adds Rollup 5 support and Node type dependencies.
packages/​url/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​typescript/​test/​test.js Adapts diagnostic assertions to augmented Rollup logs.
packages/​typescript/​test/​snapshots/​warnings.js.snap Updates warning snapshots for augmented logs.
packages/​typescript/​test/​snapshots/​tslib.js.snap Updates the missing-tslib error snapshot.
packages/​typescript/​package.json Adds Rollup 5 support and updates Node types.
packages/​terser/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​swc/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​sucrase/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​strip/​test/​rollup-build.test.js Adds a stripping build smoke test.
packages/​strip/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​run/​test/​test.js Updates expected plugin error prefixes.
packages/​run/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​replace/​test/​sourcemaps.js Updates sourcemap warning expectations.
packages/​replace/​test/​snapshots/​misc.js.snap Updates the plugin warning snapshot.
packages/​replace/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​pluginutils/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​node-resolve/​test/​test.mjs Expects additional resolver importer metadata.
packages/​node-resolve/​test/​snapshots/​test.mjs.snap Updates the deprecation warning snapshot.
packages/​node-resolve/​test/​prefer-builtins.js Updates the built-in preference warning expectation.
packages/​node-resolve/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​multi-entry/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​legacy/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​inject/​test/​rollup-build.test.js Adds an injected-import build smoke test.
packages/​inject/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​image/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​html/​test/​snapshots/​test.js.snap Updates dynamic-import output and warning snapshots.
packages/​html/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​graphql/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​esm-shim/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​eslint/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​dynamic-import-vars/​test/​snapshots/​rollup-plugin-dynamic-import-vars.test.js.snap Updates generated chunk hashes.
packages/​dynamic-import-vars/​test/​rollup-plugin-dynamic-import-vars.test.js Updates the missing-files warning expectation.
packages/​dynamic-import-vars/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​dsv/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​data-uri/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​commonjs/​test/​test.js Updates diagnostic formatting expectations.
packages/​commonjs/​test/​snapshots/​function.js.snap Refreshes generated bundle snapshots.
packages/​commonjs/​test/​fixtures/​function/​warn-this-resolve-without-options/​_config.js Updates the resolver warning prefix.
packages/​commonjs/​test/​fixtures/​function/​strict-requires-debug-none/​_config.js Updates the wrapping diagnostic prefix.
packages/​commonjs/​test/​fixtures/​function/​module-side-effects-late-entry/​_config.js Adjusts the expected generated entry filename.
packages/​commonjs/​test/​fixtures/​function/​custom-options/​_config.js Expects additional resolver importer metadata.
packages/​commonjs/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​buble/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​beep/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​babel/​test/​as-output-plugin.mjs Updates warning and chunk-hash expectations.
packages/​babel/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​auto-install/​test/​pnpm.js Checks root lockfile preservation during fixture installs.
packages/​auto-install/​test/​pnpm-bare.js Checks root lockfile preservation during bare installs.
packages/​auto-install/​test/​fixtures/​pnpm/​pnpm-workspace.yaml Anchors workspace detection to the fixture.
packages/​auto-install/​test/​fixtures/​pnpm/​.npmrc Allows dependency installation at the fixture root.
packages/​auto-install/​test/​fixtures/​pnpm-bare/​pnpm-workspace.yaml Anchors workspace detection to the bare fixture.
packages/​auto-install/​test/​fixtures/​pnpm-bare/​.npmrc Allows dependency installation at the bare fixture root.
packages/​auto-install/​package.json Adds Rollup 5 peer support and catalog usage.
packages/​alias/​test/​alias.test.ts Expects additional resolver importer metadata.
packages/​alias/​package.json Explicitly supports Rollup 4–5 and uses the catalog.

Review effort: Balanced

Comment thread pnpm-workspace.yaml Resolved
@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch from 138dee6 to 08718f0 Compare November 3, 2026 05:42
@lukastaegert lukastaegert changed the title feat(alias,auto-install,babel,beep,buble,commonjs,data-uri,dsv,dynamic-import-vars,eslint,esm-shim,graphql,html,image,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript,url,virtual,yaml): support rollup 5 feat(alias,auto-install,beep,buble,commonjs,data-uri,dsv,dynamic-import-vars,eslint,esm-shim,graphql,image,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript,url,virtual,yaml): support rollup 5 Nov 3, 2026
@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch 3 times, most recently from 6a4c2b9 to 3eaada2 Compare November 3, 2026 06:45
@TrickyPi

Copy link
Copy Markdown
Member

Hey @lukastaegert, while working on #2017 I realized a few other plugins here also break with import attributes in Rollup 5 and need rawId fixes, so I opened #2050 (dsv), #2051 (yaml), #2052 (image), #2054 (virtual), #2055 (graphql), and #2056 (url).

Also, commonjs needs a fix too, which depends on rollup/rollup#6653. Could we publish rollup@5.0.0-3 so I can open that PR?

@lukastaegert

Copy link
Copy Markdown
Member Author

@TrickyPi Thanks for looking into this! rollup@5.0.0-3 is now released, so you can update your PRs. To avoid duplication, I will remove the packages for which you opened PRs from this blanket PR.
As far as I see it, v5.0.0-3 is now complete with regard to potential breaking changes. There is one source map improvement I am considering, but it should not have any impact on plugins, so I think we should be fine to start releasing new plugin versions based on that.

@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch from 00fbf14 to a492f14 Compare November 27, 2026 05:20
@lukastaegert lukastaegert changed the title feat(alias,auto-install,beep,buble,commonjs,data-uri,dsv,dynamic-import-vars,eslint,esm-shim,graphql,image,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript,url,virtual,yaml): support rollup 5 feat(alias,auto-install,beep,buble,commonjs,data-uri,dynamic-import-vars,eslint,esm-shim,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript): support rollup 5 Nov 27, 2026
@lukastaegert

Copy link
Copy Markdown
Member Author

@TrickyPi One question about the commonjs fix: If it depends on rollup/rollup#6653, can we still release it before rollup@5 is still released? To my understanding, the commonjs plugin was working with current rollup 5? It would be nice to have versions for all plugins that work with both latest rollup 4 and rollup 5 before we release rollup 5.

@TrickyPi

Copy link
Copy Markdown
Member

@TrickyPi One question about the commonjs fix: If it depends on rollup/rollup#6653, can we still release it before rollup@5 is still released? To my understanding, the commonjs plugin was working with current rollup 5? It would be nice to have versions for all plugins that work with both latest rollup 4 and rollup 5 before we release rollup 5.

@lukastaegert Yes, it stays compatible with Rollup 4 and can be released before Rollup 5. I only needed 5.0.0-3 to implement and test the Rollup 5 side.

And yeah, regular builds already work fine on Rollup 5, it's just importing CJS modules with import attributes that breaks. I've opened #2057 for commonjs, so feel free to drop it from this PR as well.

@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch from a492f14 to 857c155 Compare November 28, 2026 05:34
@lukastaegert lukastaegert changed the title feat(alias,auto-install,beep,buble,commonjs,data-uri,dynamic-import-vars,eslint,esm-shim,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript): support rollup 5 feat(alias,auto-install,beep,buble,data-uri,dynamic-import-vars,eslint,esm-shim,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript): support rollup 5 Nov 28, 2026
@lukastaegert

Copy link
Copy Markdown
Member Author

feel free to drop it from this PR as well.

Done

@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch from 857c155 to c12d038 Compare November 28, 2026 06:02
@lukastaegert
lukastaegert force-pushed the simple-rollup-5-updates branch from c12d038 to 2d3cbce Compare December 4, 2026 05:12
@lukastaegert lukastaegert changed the title feat(alias,auto-install,beep,buble,data-uri,dynamic-import-vars,eslint,esm-shim,inject,legacy,multi-entry,node-resolve,pluginutils,replace,run,strip,sucrase,swc,terser,typescript): support rollup 5 feat(alias,auto-install,beep,esm-shim,multi-entry,run,terser): support rollup 5 Dec 4, 2026
Comment thread packages/alias/test/alias.test.ts Resolved
Extend the peer dependency range and test against the upcoming Rollup 5 release.
Extend the peer dependency range and test against the upcoming Rollup 5 release. Also anchor pnpm workspace detection to the fixture so its installs no longer rewrite the workspace lockfile.
Extend the peer dependency range and test against the upcoming Rollup 5 release.
@lukastaegert

Copy link
Copy Markdown
Member Author

I created some more PRs for packages that would profit from minor adjustments. This PR is now reduced to the remaining ones.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approved

No active review issues are reported for the Rollup 5 compatibility updates.

No open issues 🎉

2 resolved since last review
1 file not reviewed
  • pnpm-lock.yaml: Generated file

Review effort: Balanced

@lukastaegert
lukastaegert merged commit 32f5772 into master Dec 4, 2026
7 checks passed
@lukastaegert
lukastaegert deleted the simple-rollup-5-updates branch December 4, 2026 07:57
lukastaegert added a commit that referenced this pull request Dec 4, 2026
The release run that published @rollup/plugin-alias@6.1.0 pushed the version commit but had its tag push rejected by GitHub, so the workflow's cleanup step never ran. That step is what commits the changelog versioner writes after it has already committed the version bump, so the entry was lost. This restores it verbatim from what versioner generates for the #2037 commit.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants