Skip to content

Conversation

@hi-ogawa
Copy link
Contributor

@hi-ogawa hi-ogawa commented Aug 1, 2025

Description

I noticed a redundant server hmr on Waku example where it uses tailwind and typegen. Any change causes an auto-generated type files pages.gen.ts to be updated and it's doubly causing server hmr refetch.

This won't be necessary after vitejs/vite#20391 (7.1.0-beta.1), but a workaround on rsc plugin side is fairly simple, so let's include this for now.

Also we didn't have tests to verify there's no redundant server hmr. Let's add such tests.

@hi-ogawa hi-ogawa marked this pull request as ready for review August 1, 2025 02:07
@hi-ogawa hi-ogawa added the trigger: preview Trigger pkg.pr.new label Aug 1, 2025
@pkg-pr-new
Copy link

pkg-pr-new bot commented Aug 1, 2025

Open in StackBlitz

npm i https://pkg.pr.new/@vitejs/plugin-react@658
npm i https://pkg.pr.new/@vitejs/plugin-react-oxc@658
npm i https://pkg.pr.new/@vitejs/plugin-rsc@658
npm i https://pkg.pr.new/@vitejs/plugin-react-swc@658

commit: 8a9e3f8

hi-ogawa added a commit to hi-ogawa/waku that referenced this pull request Aug 1, 2025
@hi-ogawa hi-ogawa merged commit c1383f8 into main Aug 1, 2025
22 checks passed
@hi-ogawa hi-ogawa deleted the 08-01-fix_rsc_avoid_unnecessary_server_hmr_due_to_tailwind_module_deps branch August 1, 2025 02:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

trigger: preview Trigger pkg.pr.new

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant