I configured the proxy like this in vite.config.js. I ran npm run dev. It works. The endpoint returns the data. Below is the image of vite.config.js

Now the problem is when i build this application using npm run build. It creates dist and when i run this dist with npx serve dist. Application runs but when hitting the endpoint it gives error.Below are the screenshots. Even when username and password is sent, the payload is still empty



Top comments (0)