Return proper status codes (404, 302) from client-side Single Page Application
nginx-forum at forum.nginx.org
Mon Aug 8 16:59:05 UTC 2016
> If going so far to hit api server anyway, why not proxy all requests
> (except assets) and serve the index page if 200 and request type is
> html? nginx then can intercept errors and return correct html error
Yes, that would be possible. But – if I understand you correctly – my
backend would then need to serve the index page itself, and therefore be
highly coupled to the frontend.
Currently, my backend does not have any knowledge about the frontend
Thanks for your input.
Posted at Nginx Forum: https://forum.nginx.org/read.php?2,268827,268847#msg-268847
More information about the nginx