You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was
No response
Description
ng serve --proxy-config proxy.conf.json is having no effect. There is no error message but no proxying is done.
The file proxy.conf.json exists and is in the same directory as the angular.json. Setting serve.options.proxyConfig in angular.json similarly has no effect. Calls to /api are not proxied, they are redirected back to / as if no proxying was active. There is also no message in the console that ng serve is now proxying.
Run ng serve --port 7073 --proxy-conf or ng serve --proxy-conf proxy.conf.json (the docs are ambiguous).
Call http://localhost:7073/api - expect it to be proxied to localhost:7071 but it just redirects back to /
Hi @cawoodm, I am unable to replicate this problem. Can you setup a minimal repro please?
You can read here why this is needed. A good way to make a minimal repro is to create a new app via ng new repro-app and adding the minimum possible code to show the problem. Then you can push this repository to github and link it here.
This might be related to your directory structure so its really important to get an accurate repro to diagnose this.
Command
serve
Is this a regression?
The previous version in which this bug was not present was
No response
Description
ng serve --proxy-config proxy.conf.json
is having no effect. There is no error message but no proxying is done.The file
proxy.conf.json
exists and is in the same directory as theangular.json
. Settingserve.options.proxyConfig
inangular.json
similarly has no effect. Calls to/api
are not proxied, they are redirected back to/
as if no proxying was active. There is also no message in the console that ng serve is now proxying.proxy.conf.json
Minimal Reproduction
Run
ng serve --port 7073 --proxy-conf
orng serve --proxy-conf proxy.conf.json
(the docs are ambiguous).Call http://localhost:7073/api - expect it to be proxied to localhost:7071 but it just redirects back to /
Exception or Error
Your Environment
Anything else relevant?
No response
The text was updated successfully, but these errors were encountered: