hydrogen
hydrogen copied to clipboard
[BUG] Throw a meaningful error if storefront API required env vars are `undefined` in production
Describe the bug
Currently we attempt to make api calls even if some of the required env vars (like SHOPIFY_STOREFRONT_API_PUBLIC_TOKEN) are undefined.
To Reproduce
rename Oxygen?.env?.SHOPIFY_STOREFRONT_API_PUBLIC_TOKEN to Oxygen?.env?.SHOPIFY_STOREFRONT_API_PUBLIC_TOKEN_I_DONT_EXIST_IN_PRODUCTION
Expected behaviour A clear error message indicating what required env vars are not available in production.