commerce-ui
Presentational components for commerce concepts: an address card, form and address book, a price summary, payment methods and an approval status badge. They take their data as props and fetch nothing, so a feature package or your own page can render them.
Get started
Install the package with the peer dependencies it needs. It comes from the Evolve registry, which needs a one-time sign-in.
pnpm add @evolve-storefront/commerce-ui next next-intl reactRequirements5
@labdigital/graphql-fetcher>=3optionalgraphql>=16optionalnext>=16.2.11 <17next-intl>=4react>=19Import its styles in the stylesheet where you load Tailwind. Without them the components render unstyled.
@import "@evolve-storefront/commerce-ui/styles.css";Wrap your app in
AddressConfigProvider. Setup lists its props.Add its translations to your message files with
evolve messages.
Then render it on a page:
import { AddressCard, AddressCardHeader, AddressCardTitle, AddressLines,} from "@evolve-storefront/commerce-ui/address-card";import { type AddressFields, formatAddressLines, fullName } from "@evolve-storefront/core/address";
export function ShippingAddress({ address, locale }: { address: AddressFields; locale: string }) { return ( <AddressCard> <AddressCardHeader> <AddressCardTitle>{fullName(address)}</AddressCardTitle> </AddressCardHeader> <AddressLines lines={formatAddressLines(address, { locale, includeName: false })} /> </AddressCard> );}Components
What you place on your pages. Each one has a preview, its props, and how to change its layout.
Hooks
2 hooks to read and change the data yourself, for when you build your own UI. All hooks
More in this package
- Setup and server: what the package needs in your project.
- Advanced: schemas, other functions and constants, types.

