Skip to content
This repository was archived by the owner on Mar 19, 2026. It is now read-only.

fix: merge tsconfig jsx options even when oxc.jsx.runtime is set - #376

Merged
sapphi-red merged 1 commit into
vitejs:rolldown-vitefrom
hi-ogawa:fix-oxc-jsx-option-tsconfig-merging
Aug 18, 2025
Merged

sapphi-red merged 1 commit into
vitejs:rolldown-vitefrom
hi-ogawa:fix-oxc-jsx-option-tsconfig-merging

Conversation

@hi-ogawa

@hi-ogawa hi-ogawa commented Aug 18, 2025 •

Copy link
Copy Markdown

Description

Related vitejs/vite-plugin-react#726

This change is necessary to support following two cases:

  • tsconfig jsx preserve + react plugin zero config
    • this works on current vite esbuild
  • tsconfig custom jsxImportSource + react plugin zero config
    • this worked before react plugin v5.0.0

@pkg-pr-new

pkg-pr-new Bot commented Aug 18, 2025

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/vitejs/rolldown-vite/@vitejs/plugin-legacy@376
npm i https://pkg.pr.new/vitejs/rolldown-vite@376

commit: 087b4af

@hi-ogawa hi-ogawa changed the title fix: use tsconfig importSource when explicit oxc.jsx.runtime = "automatic" fix: merge tsconfig importSource when explicit oxc.jsx.runtime = "automatic" Aug 18, 2025
hi-ogawa added a commit to vitejs/vite-plugin-react that referenced this pull request Aug 18, 2025
@hi-ogawa

Copy link
Copy Markdown
Author

test-build still failed on vitejs/vite-plugin-react#726. we need to change native plugin too https://github.com/rolldown/rolldown/blob/c3e5c84a2836b8fbdae30c1c4e4aad8c8f8e0744/crates/rolldown_plugin_transform/src/utils.rs#L137-L138

@sapphi-red

Copy link
Copy Markdown
Member

@hi-ogawa Are you going to create a PR to the native plugin?

@hi-ogawa

Copy link
Copy Markdown
Author

Yes, I'll port the change to native plugin.

@hi-ogawa hi-ogawa changed the title fix: merge tsconfig importSource when explicit oxc.jsx.runtime = "automatic" fix: merge tsconfig jsx options even when oxc.jsx.runtime is set Aug 18, 2025
@hi-ogawa hi-ogawa changed the title fix: merge tsconfig jsx options even when oxc.jsx.runtime is set fix: merge tsconfig jsx options even when oxc.jsx.runtime is set Aug 18, 2025
github-merge-queue Bot pushed a commit to rolldown/rolldown that referenced this pull request Aug 18, 2025
github-merge-queue Bot pushed a commit to rolldown/rolldown that referenced this pull request Aug 18, 2025
@sapphi-red
sapphi-red merged commit e6eb30a into vitejs:rolldown-vite Aug 18, 2025
@hi-ogawa
hi-ogawa deleted the fix-oxc-jsx-option-tsconfig-merging branch August 18, 2025 08:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants