I am doing an AJAX request using the Github API by the axios and wanted to know how I do for while loading the information, it gives a console.log('carregando');
and create a component written "loading", and after that it deletes the loading messages.
This is my current code:
axios.get('https:api.github.com/users/marceloh13')
.then(function(response){
console.log(response);
console.log(response.data.avatar_url)
})
.catch(function(error){
console.log(error);
});