hydrogen icon indicating copy to clipboard operation
hydrogen copied to clipboard

Fix server build entry in template

Open frandiox opened this issue 3 weeks ago • 1 comments

The server build entry import was modified in the RR7 upgrade PR to be a dynamic import. I'm not sure why since it works as a static import as well. I've excluded this from ESLint to fix the errors.

🔴 Using a dynamic import means Vite needs to process your app code at runtime during the first request from your browser, which delays page rendering by a couple of seconds (you see a blank page for a while):

image

🟢 While a static import can be discovered by Vite earlier and preloaded in parallel to other work before your browser even opens:

image

frandiox avatar Dec 11 '25 04:12 frandiox