-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
Feature Request: Using Deno as a server with vite #6553
Comments
you can follow Deno compatability here denoland/deno#12577 |
That is not what I meant I dont want to run the vite code on Deno but create a Deno Server with vite. |
then please include error message and preferably a reproduction |
The main question is if this is something a plugin can not fix / handle is that something that is wanted in vite or not. And I'm happy to work on a PR! reproduction see https://github.com/mathe42/vite-deno-repro The modified client.mjs is the same I only removed some usage of |
Got it working with a plugin... Also for NodeJS development! For all interested https://github.com/mathe42/vite-plugin-server |
Clear and concise description of the problem
I thought that it should be quite easy to modify vite so I can use it together with deno:
The following example my Deno entrypoint is
src/server.ts
than I could start vite and start deno with(The
-r
flag is so deno don't use cached files)I run into some errors as HTMLElement and CustomElements and location is not defined in deno but I could modify the dist/client/client.mjs file so Deno runs and I also got a simple HMR working.
(Note that I want to use the SAME vite instance to develop my vue application)
Suggested solution
I'm quite shure that this is nothing a plugin can handle (maybe by modify the
@vite/client
import but that seems like a hack and I'm not shure how easy this can be done).Is this something to add to 'core' vite? - If yes I'm happy to work on it and create a PR.
Changes would include
CLIENT_PUBLIC_PATH
or@vite/client
Alternative
No response
Additional context
No response
Validations
The text was updated successfully, but these errors were encountered: