1
The configuration of my Laravel Cors is this.
'supportsCredentials' => false,
'allowedOrigins' => ['*'],
'allowedHeaders' => ['*'],
'allowedMethods' => ['*'],
'exposedHeaders' => [],
'maxAge' => 0,
'hosts' => [],
The configuration of my request is
axios.get('http://api2u.oo/api/rede/1', {
headers: {
'Access-Control-Allow-Origin': '*',
},
crossdomain: true
})
.then(function (response) {
console.log(response);
})
.catch(function (error) {
console.log(error);
});
Laravel 5.5.*
The mistake
How to solve?