-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: vite runtime api #10091
WIP: vite runtime api #10091
Conversation
🦋 Changeset detectedLatest commit: 5f42edb The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Current dependencies on/for this PR:
This stack of pull requests is managed by Graphite. |
907b3ce
to
fff27ce
Compare
cc4abb2
to
a5decba
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is blocked because it contains a minor
changeset. A reviewer will merge this at the next release if approved.
!preview vite-runtime-api |
Snapshots have been released for the following packages:
Publish Log
Build Log
|
a5decba
to
5f42edb
Compare
!preview vite-runtime-api |
Snapshots have been released for the following packages:
Publish Log
Build Log
|
Since this is postponed until we see how the API shapes and it might be a bigger refactor, since we already discover on Discord, I'll close this PR. We can either reopen, create a new one, or decide later what to do. |
UPDATE: After some Discord discussions, we have a better understanding, my goal is to get a
workerd
runtime implement, without caring about backward compatibility &or a default node runtime. If we have a POC forworkerd
, we can decide if we put this behind an external flag, which disables current behavior and only allows custom runtime, or if we want to investigate some more time how to get both running in parallel and automatically choosing the right oneUPDATE: After some exploration, I'm pretty sure this is not the correct approach. (see messages following: https://discord.com/channels/830184174198718474/845430950191038464/1212079358701731880)
Changes
server.ssrLoadModule
https://vitejs.dev/guide/api-vite-runtimewokerd
if using the Cloudflare adapter, which would make sure that dev has the same runtime as prod, and users won't face issues with incompatible or different behaviour between dev & prod.a) https://github.com/sapphi-red/vite-envs/blob/main/examples/cloudflare-pages/vite.config.ts#L17-L18
b) https://github.com/dario-piotrowicz/vite-runtime-5.1-experimentations/blob/a2d2d9aabbce5f058f530710730a1fdf5773eb80/examples/basic-handler/vite.config.js#L40
c) Back to Vite 🎉 Shopify/hydrogen#1728
d) https://github.com/hi-ogawa/vite-plugins/tree/ba5d995046cffc0fd368dd3c3a4d05f9d2db29dc/packages/vite-node-miniflare
Testing
Docs