Checkout ​
Recipes for the cart and checkout flows, from the first line item to a placed order and its payment.
Cart
Understand why every cart write returns the whole recalculated cart, the shared cart state behind useCart, the line item operations, and the errors map a 2xx response can carry.
Payment
Understand why payment starts after the order exists, what the handle-payment response does and does not tell you, how the return page reads the transaction state, and when the method can still be changed.
Checkout and Order Placement
Understand why the shipping and payment method lists are recalculated on every change, how a method selection is a context patch, what the order request actually carries, and why the cart is gone afterwards.