Update React Editor integration and clean up template

This commit is contained in:
Rami Bitar
2026-08-15 13:47:33 -04:00
parent 0a7ea0bf6b
commit 0fb6cef226
82 changed files with 113 additions and 913 deletions
-4
View File
@@ -12,7 +12,6 @@ export interface ShopPolicy {
url: string;
}
// Handles Shopify uses for each policy — also the routes under /policies/[handle].
export const POLICY_HANDLES = [
'terms-of-service',
'privacy-policy',
@@ -21,8 +20,6 @@ export const POLICY_HANDLES = [
'subscription-policy',
] as const;
// Policies change rarely, so this reads through the cached client (revalidated
// hourly) rather than the no-store one used for carts and products.
export async function getShopPolicies(): Promise<ShopPolicy[]> {
try {
const data = unwrapStorefrontResult(
@@ -34,7 +31,6 @@ export async function getShopPolicies(): Promise<ShopPolicy[]> {
(policy): policy is ShopPolicy => Boolean(policy?.handle)
);
} catch (err) {
// A storefront without policies configured shouldn't break the footer.
console.error('Failed to load shop policies:', err);
return [];
}