Skip to content

Implement Sort Functionality on All Products Page #96

@Alexandrbig1

Description

@Alexandrbig1

Priority: High
Difficulty: Advanced
Type: Frontend Feature


Description

Enhance the All Products page (/products) with a fully functional Sort by dropdown.
Currently, the button is visible but not functional. This task will implement sorting logic for the product grid.


Requirements

  1. Sort Dropdown

    • Default option: Best Selling.
    • Additional options:
      • A-Z (alphabetical ascending by product title).
      • Z-A (alphabetical descending by product title).
      • Price - Low to High.
      • Price - High to Low.
      • Rating - Low to High.
      • Rating - High to Low.
  2. Sorting Logic

    • Products should re-render immediately when a new sort option is selected.
    • Sorting happens on the client side (frontend), using the products already fetched from the backend.
  3. UI/UX

    • Show active sort option in the dropdown.
    • Smoothly update the product grid without a full page reload.
    • Maintain compatibility with wishlist, cart, and recently viewed logic.

Asdsets:

Image


Acceptance Criteria

  • Sort by dropdown works with all listed options.
  • Products are re-rendered in the correct order based on selected sort option.
  • Default is Best Selling (placeholder until backend provides actual logic).
  • Works together with other features (filters, infinite scroll, etc.).

Metadata

Metadata

Assignees

Labels

advancedComplex/advanced tasks or featuresapiAPI endpoints & integrationaxiosPromise-based HTTP clientfrontendTasks related to the frontend (React, Vite, TailwindCSS, UI components, pages)hacktoberfestSpecial issue for Hacktoberfesthacktoberfest-2025Special issue for Hacktoberfest 2025priority: highNeeds attention ASAP

Projects

Status

Done

Relationships

None yet

Development

No branches or pull requests

Issue actions