DEV Community

AjayMalhotra
AjayMalhotra

Posted on

3 1

No 'Access-Control-Allow-Origin

I am making an application with angular and backend as laravel but when I hit the api, I get "No 'Access-Control-Allow-Origin' header is present on the requested resource" and I am able to solve this issue and here I sharing that and hope it will help others.

Access-Control-Allow-Origin

Thank you
Therichpost

Top comments (2)

Collapse
 
abelagoi profile image
Agoi Abel Adeyemi

Hi there, you can check out this package: github.com/barryvdh/laravel-cors.

I personally use it to solve this problem too.

Collapse
 
ajaydeveloper profile image
AjayMalhotra

nice

AWS Security LIVE!

Join us for AWS Security LIVE!

Discover the future of cloud security. Tune in live for trends, tips, and solutions from AWS and AWS Partners.

Learn More

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay