New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: proxy bypass do nothing with object result #10209
Conversation
Maybe we could just remove this part for the following reason? vite/packages/vite/src/node/server/middlewares/proxy.ts Lines 122 to 125 in 7bc0169
|
yes, i was just reading the source code and found this problem, I am not sure why there is no description in docs really. so maybe remove this part is reasonable |
any results ? +_+ |
Hey @cisen, would you explain the context behind this PR? Let's wait a bit, but I agree with @sapphi-red, if this wasn't working, better to remove this code in 3.2. We can add the feat once we have a real use case reported. |
|
I don't understand without any explanations, but by reading that PR, I guess this implementation was incomplete at the first place. So I think we could remove this. |
Why remove useful functionality if it can be fixed with a simple change? |
Because this wasn't working and not documented anywhere and nobody requested this feature. |
actually, there is no doc about bypass that with a |
There is: vite/packages/vite/src/node/server/middlewares/proxy.ts Lines 22 to 29 in 0d73473
|
I mean the Type of return value is |
5b449f4
to
c349f26
Compare
@sapphi-red @patak-dev could U plz review for this .+_+ |
I agree with @sapphi-red here. And it looks like @cisen is pointing to a PR they did where they also removed this block: #2421. If someone needs this feature, let's get a proper issue or PR explaining the use case, documenting it, and adding tests. |
Description
if
bypass
return an object, 'viteProxyMiddleware' just handle the options and return directlyAdditional context
What is the purpose of this pull request?
Before submitting the PR, please make sure you do the following
fixes #123
).