Product list with cart made using React and Tailwindcss

Solution retrospective
Had a slight issue where when I remove an item in my cart by clicking the "x" icon, it removes it but the state isn't updated on the dessert grid.
Meaning, if I had 4 items added into the cart and I delete them with the "x", the cart is empty yes, but the grid still shows that I have 4 items added. I need to manually decrement the quantity. So if there is a way to fix it, it would be great to know
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on Karim Chehab's solution.
Join our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord