Checks
Describe the bug (be clear and concise)
With the following
app.use(
createProxyMiddleware('/api/v1/xyz', {
target: 'https://example.com/api/v1/xyz',
changeOrigin: true,
})
);
if a request is being made https://myapp.com/api/v1/xyz?param1=value the proxied request is translating to https://example.com/api/v1/xyz/?param1=value resulting in 404. ( Extra / is being added )
This was not the case with v2 and even with v3 legacy mode.
Step-by-step reproduction instructions
1. Add proxy as described above
2. send the request with query params
Expected behavior (be clear and concise)
No "/" should be added,
How is http-proxy-middleware used in your project?
orx-aim-azure-bff@1.0.0 proxy-app
├── http-proxy-middleware@3.0.0
└─┬ react-scripts@5.0.1
└─┬ webpack-dev-server@4.15.1
└── http-proxy-middleware@2.0.6
What http-proxy-middleware configuration are you using?
app.use(
createProxyMiddleware('/api/v1/xyz', {
target: 'https://example.com/api/v1/xyz',
changeOrigin: true,
})
);
### What OS/version and node/version are you seeing the problem?
```shell
Windows 11, Node 20
Additional context (optional)
No response
Checks
http-proxy-middleware.Describe the bug (be clear and concise)
With the following
if a request is being made
https://myapp.com/api/v1/xyz?param1=valuethe proxied request is translating tohttps://example.com/api/v1/xyz/?param1=valueresulting in 404. ( Extra / is being added )This was not the case with v2 and even with v3 legacy mode.
Step-by-step reproduction instructions
Expected behavior (be clear and concise)
No "/" should be added,
How is http-proxy-middleware used in your project?
orx-aim-azure-bff@1.0.0 proxy-app ├── http-proxy-middleware@3.0.0 └─┬ react-scripts@5.0.1 └─┬ webpack-dev-server@4.15.1 └── http-proxy-middleware@2.0.6What http-proxy-middleware configuration are you using?
Additional context (optional)
No response