How not to redirect any /api/
calls?
#11882
binarykitchen
started this conversation in
General
Replies: 1 comment
-
Add rewrites(used to exclude certain paths from being rewritten) see this: historyApiFallback |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
My app does plenty of HTTP API and Web Socket calls to the backend.
React-router is causing too many invalid redirects.
All those API calls start with the
/api/
path. How can I configure react-router not to redirect any of these back to index.html?This is the webpack-dev-server configuration I'm using:
Thanks to the
verbose
flag, I see this in the console:Read the official documentation about four times, still no answer about that. I do not want to use a loader as these API calls can happen in between route changes.
Thanks for any hints
Beta Was this translation helpful? Give feedback.
All reactions