Nuxt dev server from code server
I started a dev server(hmr) from a self hosted code-server. Code server serves from https://example.com/proxy/3000. the dev servers runs but assets(css,js,images) don't load properly. I figured it has something to do with proxying but I'm unsure how to go about it, I assume i should proxy https://example.com to https://example.com/proxy/3000. But i don't know if to use the vite, app, or nitro dev proxy option.
12 Replies
@Jacek Made some progress, lotf of the assets load now but some still don't load properly maybe it has something to do with hmr?
Seems unlikely, but I cannot rule it out since I have very little knowledge about your project setup.
Is there anything interesting in DevTools Network tab?
@Jacek Sorry about the late reply. It says
Dont load = HMR or initially?
I think vite uses ws at some port notify hmr
You need to proxy that too
If you want to temporarly deploy your dev state somewhere, you might better use a tunnel (e.g. localtunnel)
Examples showing WS usage usually include protocol adjustment
let me know if it helps 🙂
It doesn't hot module reload.
I have coder server running on a vps i want to be able to run a dev server from there, hope this makes sense.
Where do i include this? as a middleware or?
Does this have the same effect as running ?
@Jacek When i tried that it says socket hangup
Hey
Hello