'use client'; import { useStoreInfo } from '@/core/providers/store-provider'; import { resolveStoreName } from '@/core/lib/store-name'; /** * Client twin of `resolveStoreName()` — the one call for "what is this store * called?" inside `'use client'` components, exactly as `useCurrency()` is * for the currency code. Live `storeInfo.name` wins; the build-time * `NEXT_PUBLIC_STORE_NAME` and then the scaffold literal fill in before the * provider has resolved. See `store-name.ts` for the chain. * * @param override pass when the caller already has a more specific name. */ export function useStoreName(override?: string | null): string { const { storeInfo } = useStoreInfo(); return resolveStoreName(storeInfo, override); }