react-ecommerce
react-ecommerce copied to clipboard
Cart Persistence on Refresh
Description
We would like to persist a customer's cart on refresh. This means we need to store their cart in a persistent browser storage. Check out the localStorage API to build this enhancement.
How to Reproduce
- Run app locally
- add item to cart
- Refresh page
- see that cart is empty
https://user-images.githubusercontent.com/2349518/166158707-5330e28e-94e9-4aeb-899f-ddddf45719e9.mp4
Deliverables
- [ ] Cart is persisted when user does refresh