Skip to content

Product Carousel reordering is not working when I drag and drop products in the editor #2790

@jayeshbharadva

Description

@jayeshbharadva

Describe the bug
When using the Product Carousel component with Makeswift, manually reordering products in the Makeswift editor does not affect the render order on the storefront. The products always render in the default order returned by the BigCommerce API (usually sorted by ID) rather than the specific order defined in the productIds prop.

To Reproduce
Steps to reproduce the behavior:

  1. Open the Makeswift builder/editor.
  2. Add a Product Carousel component to a page.
  3. Select specific products manually (e.g., Product A (ID: 10), Product B (ID: 5)).
  4. Drag and drop to rearrange them so that Product B (ID: 5) comes before Product A (ID: 10).
  5. Save/Publish and view the component.

Result: The carousel displays Product A first, then Product B (ignoring the manual order).

Previously working?
I don't this so it was ever working as this looks like a miss at start.

Expected behavior
The carousel should display products in the exact order arranged by the user in the Makeswift editor.

Evidence
Vimeo Link

Additional context
It appears the component renders the list based directly on the API response order, which defaults to sorting by ID, rather than preserving the order of the product IDs passed from the editor configuration.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions