How can I send requests from GitHub Pages without running into CORS?

So I tried to host a little project I made in React.

GitHub GitHub Pages

But, everytime I try to send a request to MetaWeather, I get this back. Error

I don't know what I should be doing different. I used Axios, but even with Fetch the same thing happens.

Upvotes: 0

Views: 1311

Answers (1)

Vaibhav Rai
Vaibhav Rai

Reputation: 168

You can use https://cors-anywhere.herokuapp.com/ but remember it should be enabled from there side also

Upvotes: 2

Related Questions