I’ve read a lot of topics here in this forum and also out there at google’s results, but I’m still stuck to this proxy thing. I can’t get it working for my local development.
I already setup a host at my local machine that is reachable unter http://ionicfez:8888 (did it with MAMP).
I started a new ionic project und defined the router so that localhost:8100/test ist pointing to a view “Test.vue”.
Here I’m calling a simple request to an “api” that only has 1 php file at the moment.
I’ve set up the “proxies” in ionic.config.json to proxy the api directory to http://ionicfez:8888
As the result, I get the response from the php file as an script -it is not interprated
When I call http://localhost:8100/api or http://localhost:8100/public/api browser’s console says, that vue’s router has no route for that (so it is not handled by the defined proxy)
This is my project structure. Pretty simple and out of the box.
After all I surrender. I can’t get it up and running as I did this many times before in vue.js projects (without ionic).
Is there anybody out there, who have an idea, why this is not working as expected?
I’ll attach some screenshots of my projects file structure, the ionic.config.json and the method that calls the axios request.
Thanks in advance for any hint.