Command
proxy: { "/api": "http://localhost:3001" }Explanation
Configure proxy in vite.config.js to forward API requests to backend server during development.
Examples
Proxy API calls to backend
proxy: { "/api": "http://localhost:3001" }Proxy WebSocket connections
proxy: { "/socket.io": { target: "ws://localhost:3001", ws: true } }