Skip to content

fix: use oxc instead of esbuild when Rolldown is detected#154

Open
zymotik wants to merge 1 commit intodavidmyersdev:mainfrom
zymotik:chore/issue-142-yeboster-fix
Open

fix: use oxc instead of esbuild when Rolldown is detected#154
zymotik wants to merge 1 commit intodavidmyersdev:mainfrom
zymotik:chore/issue-142-yeboster-fix

Conversation

@zymotik
Copy link
Copy Markdown

@zymotik zymotik commented Apr 1, 2026

Summary

Context

Issue #142 references this exact commit by @yeboster, and this PR ports it into the upstream repository.

Vite 8 dropped esbuild in favor of oxc for JS transforms. The plugin
was still setting `esbuild.banner` unconditionally, which triggers a
deprecation warning on Vite 8.

This uses the existing `isRolldownVite` check to pick between
`oxc.jsxInject` and `esbuild.banner` for dev banner injection,
matching how `optimizeDeps` already branches between rolldownOptions
and esbuildOptions.

Also adds ^8.0.0 to peerDependencies.

Closes davidmyersdev#142
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.

2 participants