divanov11 / proshop_django

403 stars 426 forks source link

fixed cart screen. removed item no longer get added after reloading t… #16

Open davishek7 opened 3 years ago

davishek7 commented 3 years ago

…he cartscreen

davishek7 commented 3 years ago

Right now if you delete any item from cart and refresh the page those deleted items again get added to the car because the useEffect use url parameter containing product id to add the items to the cart. So I have just used history to push the application to '/cart/' route.