Setting the file. One moment.
Subchapter 7.131
references/storefront/app-astro/layouts/SiteLayout.astro
ASTRO65 lines3 KB
---
// The site chrome for every storefront page — THIS file (header/footer/nav) plus the @theme
// token block in src/styles/global.css are what you brand. Keep:
// - the <slot name="seo-tags" /> in <head> (the product page's owner-editable SEO lands there,
// including the <title> — which is why ours is printed only when the slot is empty)
// - the global.css import (Tailwind + the design tokens every shipped component reads)
// - one <CartButton> in the header and one <CartDrawer> per page (both client:only —
// they read browser cart state and must not server-render)
// - category links in the nav (or your own menu/footer) — every category page reachable by
// a real link (`/category/<slug>`), from the live tree, so a category the owner adds later
// shows up with no code change
import CartButton from "../components/storefront/CartButton";
import CartDrawer from "../components/storefront/CartDrawer";
import { fetchCategories } from "../wix/storefront/catalog";
import type { Category } from "../wix/storefront/types";