0
Good afternoon. I have the following code in a study project on Reactjs that I am using Axios for requests.
import axios from 'axios';
var url = 'http://site3.htempurl.com';
const api = axios.create({
baseURL: url,
timeout: 1000,
headers: {'Content-Type': 'application/json'}
})
export default api;
It turns out that when I test requisicoes on an api, it changes the baserl to https, error in the request.
Image 1: Error showing that https is being sent:
Image 2: how the api is being called in the service:
What can it be?
Can add errors and show some prints?
– Marconi
I edited the question by placing the prints.
– Jonatas Lima
In the network tab returns what status?
– Marconi