Przejdź do głównej zawartości

Function: createPickupWidgetManager()

createPickupWidgetManager(options): PickupWidgetManager | null

Pick the adapter for a widget by its type.

Branching on the widget kind — not on the carrier name — is what keeps a storefront out of carrier-specific conditionals: two carriers shipping the same widget need one adapter, and a carrier that switches widgets does not break code that never named it.

Returns null for a widget this SDK version does not know. Treat that as "offer point search instead", not as an error: the API may start returning a widget before the shop upgrades.

Parameters

options

PickupWidgetMountOptions

Returns

PickupWidgetManager | null