Hi,
i try to use shopify storefront api.
So i just want for the moment display the name of the shop in the console but in Chrome i have this error :
here my code :
Index.html
# Shopify Custom Storefront App
app.js
const query = `{
shop {
name
}
}`;
function apiCall(query) {
return fetch('kokoprint.myshopify.com/api/graphql.json', {
method: 'POST',
headers: {
'Content-Type': 'application/graphql',
"Access-Control-Origin": "*",
'X-Shopify-Storefront-Access-Token': "b4b3ab6921b80585306407746e956e70"
},
"body": query
}).then(response => response.json());
}
apiCall(query).then(response => {
console.log(response)
});
Need some help please
