trying to get json from api

This commit is contained in:
2019-08-20 14:38:08 +02:00
parent 67515882c3
commit 6a2bb45fb2
4 changed files with 33 additions and 5 deletions
+5 -3
View File
@@ -1,12 +1,14 @@
import axios from 'axios'
let path = 'http://' + window.location.hostname + ':8984'
// let path = 'http://' + window.location.hostname + ':8984'
let path = 'http://dev.api.gdp.fr'
export const REST = axios.create({
baseURL: path + '/gdp',
withCredentials: true,
crossDomain: true,
// withCredentials: true,
crossorigin: true,
headers: {
'Content-Type': 'application/json'
// 'Access-Control-Allow-Credentials': true
}
})