I had made a website in laravel.Now Iam making its mobile App using Ionic 3.
I am facing an following issue while making a API call to backend of laravel.
localhost/:1 XMLHttpRequest cannot load http://xyz.dev/request/login. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8100' is therefore not allowed access.
Let say there are 12 routes defined in web.php of laravel.
Then in my project out of 12, 6 routes are for desktop web application and remaining 6 routes are prefixed with /mobile
so that I can consume it in MY API.
I am facing that issue while making any request through mobile app which is in IONIC and backend is in Larave.
Please Help me for this.