mirror of
https://github.com/siteboon/claudecodeui.git
synced 2026-06-08 22:55:50 +08:00
fix(vite): proxy /plugin-ws WebSocket requests to the backend in dev (#757)
Plugin WebSocket connections (e.g. the official Terminal plugin) hang in `npm run dev` because Vite proxies /api, /ws, and /shell but not /plugin-ws/*. Production is unaffected because the same Express server serves both the frontend and the WS gateway. Co-authored-by: Haile <118998054+blackmammoth@users.noreply.github.com>
This commit is contained in:
@@ -37,6 +37,10 @@ export default defineConfig(({ mode }) => {
|
|||||||
'/shell': {
|
'/shell': {
|
||||||
target: `ws://${proxyHost}:${serverPort}`,
|
target: `ws://${proxyHost}:${serverPort}`,
|
||||||
ws: true
|
ws: true
|
||||||
|
},
|
||||||
|
'/plugin-ws': {
|
||||||
|
target: `ws://${proxyHost}:${serverPort}`,
|
||||||
|
ws: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user