Repository navigation
feat: implement product wishlist feature with ProductCard and Wishlist page - #43
Open
omsrajput977 wants to merge 2 commits into
Open
omsrajput977 wants to merge 2 commits into
omsrajput977 wants to merge 2 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Implemented a complete Wishlist feature allowing users to add/remove products from their wishlist, view saved items on a dedicated Wishlist page, and persist wishlist state in
localStorage. Included interactive heart toggle buttons on product cards, an empty wishlist state with a call-to-action button, and a live item count badge in the navigation bar.Related Issue
Closes #18
Type of Change
Please select all applicable options:
Changes Made
WishlistContext,WishlistProvider, anduseWishlisthook to manage wishlist state with automaticlocalStoragepersistence.ProductCardcomponent with an interactive heart toggle button, category tag, pricing, and removal actions.Wishlistpage (/wishlist) that displays saved products, supports one-click item removal, "Clear Wishlist", and an empty state with a "Browse Products" button.Productscatalog page (/products) with sample developer gear data for exploring and testing the wishlist feature.Navbarwith navigation links to Products and Wishlist, including a live badge counter for saved items.html[data-theme="dark"]) support insrc/App.css.Testing
npm run lintsuccessfullyDocumentation
Screenshots / Videos
Checklist
Before submitting this pull request, please confirm:
npm run lintand resolved any issues.Additional Notes
The wishlist state automatically persists across browser refreshes using
localStorage. All components includePropTypesvalidation for type safety.