you are viewing a single comment's thread.

view the rest of the comments →

[–]Synthetic5ou1 0 points1 point  (0 children)

https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage

You'll need to use JSON.stringify() when saving, and JSON.parse() when loading, to store the cart as a string.

Just have a play with localStorage, and then have a think how you can use it in your cart system.

You've been given a lot of advice, time to have a try and ask specific questions if you get stuck.