Use this file to discover all available pages before exploring further.
The @colossal-sh/storefront-sdk provides React hooks and components for building storefronts. It wraps the Colossal Storefront GraphQL API.For a reference implementation, see the Storefront Starter Template.
Fetch project details by UID or for the current context.
Name
Type
Purpose
useStore({ uid })
Hook
Fetch store details by UID
useCurrentStore()
Hook
Fetch the current store
fetchStore({ uid })
Method
Server-side store fetch
fetchCurrentStore()
Method
Server-side current store fetch
import { useStore, useCurrentStore } from "@colossal-sh/storefront-sdk";// By UIDconst { data } = useStore({ uid: "store-uid" });const store = data?.storeDetails;// Current storeconst { data } = useCurrentStore();const store = data?.currentStore;