React Course Notes Migrating the Cart Context Exercise

Where do I need the cart context?
I need it in the cart.
I also need it in the shop component as the component needs to add items to the cart.

Cannot use useSelector() on a top level element in a module. It must be done inside a react component, or in a react hook function.


Last update : 25 mai 2024
Created : 25 mai 2024