Home > widget-integration > CombinedProductListingsController > saveCombinedListingChildToSession

CombinedProductListingsController.saveCombinedListingChildToSession() method

Persists the active combined listing child product and variant IDs to sessionStorage.

This enables the analytics module (analytic/index.js) to attribute add-to-cart, buy-now, and pre-order tracking events to the correct child product when the user interacts inside the quick-view modal.

Called after combined listing state changes: modal open, parent swatch change, and child swatch change. Clears keys when no child is active.

Signature:

saveCombinedListingChildToSession(): void;

Returns:

void