I have a Netlify project running which contains two git submodules. Module 1 is a frontend server running on React. Module 2 is an Express server that retrieves data and returns it. I am now trying to fetch a URL in order to retrieve the correct data from the backend server. But unfortunately I am getting this error: 'Unexpected token < in JSON at position 0'.
The only line in my _redirects file (located in public folder of frontend server) is now: /* /index.html 200
I have a proxy set to http://localhost:4000 (backend server) in the package.json of the frontend server.
Can someone tell me where the problem lays?
Trying to fetch data like this