useCartEvents
●cart · /react·function
Subscribe to a single cart event type for the lifetime of the calling
component. Re-subscribes whenever type or handler identity changes —
stabilize the handler with useCallback to avoid churn.
Signature
function useCartEvents(type: E, handler: Handler<E>): void;Parameters
| Name | Type | Description |
|---|---|---|
type | E | |
handler | Handler<E> |
Related
CartDevtools CartFormProps CartProviderProps AppCartConfig BaseCartActions BuyerIdentityActions CartActions CartAttributeActions