Dedicated to the Hydrogen framework, headless commerce, and building custom storefronts using the Storefront API.
Is there a way to specify a market (I mean shopify markets https://www.shopify.com/markets ) when querying the products with the storefront apis via js ?
I've tried something like
const client = ShopifyBuy.buildClient({
domain: 'my-domain.myshopify.com',
storefrontAccessToken: 'my-token',
localization:'US'
});
const client = ShopifyBuy.buildClient({
domain: 'my-domain.myshopify.com/en-US',
storefrontAccessToken: 'my-token',
});
const client = ShopifyBuy.buildClient({
domain: 'my-domain.myshopify.com/en-US',
storefrontAccessToken: 'my-token',
language: 'en-US'
});
but none of the above seems effective, when query for products
client.product.fetch(productId).then((product) => {
console.log(product);
});
i always get prices from the default market.
Solved! Go to the solution
This is an accepted solution.
This is an accepted solution.