Skip to content

Conversation

@srenge
Copy link

@srenge srenge commented Oct 26, 2025

This pull request introduces several improvements to the shopping cart and product list functionality, focusing on better cart management, UI enhancements, and code quality. The main changes include refactoring the cart logic in Redux, displaying the cart quantity in the navigation bar, improving the product list rendering, and enforcing prop types for better component validation.

Cart functionality and Redux logic:

  • Refactored addItem, removeItem, and updateQuantity reducers in CartSlice.jsx to properly handle item addition, removal, and quantity updates, ensuring items are only added once and quantities are updated correctly.
  • Updated cart actions in CartItem.jsx to dispatch Redux actions for incrementing, decrementing, and removing items, and to calculate total amounts and costs more robustly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant