CartLines

The CartLines component iterates over each cart line and renders its children within a CartLineProvider for each cart line. It also provides render props in the case where children is a function.

Example code

Props

Name Type Description
as? "ul" A ReactNode element. Valid values: ul or undefined. If ul, then each child will be wrapped with a li element.
children ReactNode | (line: UndocumentedType) => ReactNode A ReactNode element or a function that takes a cart line as an argument and returns a ReactNode.

Component type

The CartLines component is a shared component, which means that it renders on both the server and the client. For more information about component types, refer to React Server Components.