Below is quoted from Fielding's REST dissertation 6.4.3.2 Cookies
Likewise, the use of cookies to identify a user-specific “shopping basket” within a server-side database could be more efficiently implemented by defining the semantics of shopping items within the hypermedia data formats, allowing the user agent to select and store those items within their own client-side shopping basket, complete with a URI to be used for check-out when the client is ready to purchase.
For the bold part, does it mean to store the items in the page? Such as hidden elements of a form? If so, I think customer will lose his purchase when he leaves the page.
So what exactly does the hypermedia data formats
mean?