Closed wojtekmaj closed 3 months ago
Describe the bug
When using Ladle + vite-plugin-ssl with server.proxy, the following error appears on the server:
Internal server error: Header name must be a valid HTTP token [":path"]
I initially thought it's a regression of https://github.com/vitejs/vite/issues/484, but turns out it's not: workaround for https://github.com/vitejs/vite/issues/484 is still there. I dug down inside Ladle stuff and confirmed that the issue lies here:
https://github.com/tajo/ladle/blob/ff434ef02204bda9c19660edf358d151ac16a23d/packages/ladle/lib/cli/vite-dev.js#L134-L135
This piece of code lacks the exact same workaround Vite lacked back in the days.
When I replaced these two lines of code with:
https .createServer(
Ladle + vite-plugin-ssl started working flawlessly with server.proxy.
Environment
System: OS: macOS 14.1.1 CPU: (8) arm64 Apple M2 Memory: 59.30 MB / 16.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 20.9.0 - /private/var/folders/3y/swkjq1x101b76mzjgt4pm2d80000gp/T/xfs-7e9663ff/node Yarn: 4.0.0 - /private/var/folders/3y/swkjq1x101b76mzjgt4pm2d80000gp/T/xfs-7e9663ff/yarn npm: 10.1.0 - /usr/local/bin/npm bun: 1.0.12 - ~/.bun/bin/bun Browsers: Chrome: 119.0.6045.159 Edge: 119.0.2151.72 Safari: 17.1
I would like to work on this issue. Can you Please assign me this issue?
Sure, thanks!
Describe the bug
When using Ladle + vite-plugin-ssl with server.proxy, the following error appears on the server:
I initially thought it's a regression of https://github.com/vitejs/vite/issues/484, but turns out it's not: workaround for https://github.com/vitejs/vite/issues/484 is still there. I dug down inside Ladle stuff and confirmed that the issue lies here:
https://github.com/tajo/ladle/blob/ff434ef02204bda9c19660edf358d151ac16a23d/packages/ladle/lib/cli/vite-dev.js#L134-L135
This piece of code lacks the exact same workaround Vite lacked back in the days.
When I replaced these two lines of code with:
Ladle + vite-plugin-ssl started working flawlessly with server.proxy.
Environment