Checkout Area Methods

SmartCart.adjustPreviewButtonsvoid

Updates the Accelerated Checkout buttons for previewing in the Admin.

SmartCart.appendAcceleratedCheckoutvoid

Appends the '.additional-checkout-buttons' element to the SmartCart flyout

SmartCart.checkoutvoid

Performs the checkout process

SmartCart.checkoutLabelstring

Gets the label for the checkout button

SmartCart.clearAcceleratedCheckoutvoid

Removes the '.additional-checkout-buttons' element from the SmartCart flyout

SmartCart.continueShoppingLabelstring

Get the label for the Continue Shopping button

SmartCart.getAdditionalCheckoutButtonsboolean | object

Checks for the existence of the '.additional-checkout-buttons' element, which is used by the 'rebuy-smartcart-extensions.liquid' snippet

SmartCart.getCheckoutSettingsobject

gets the checkout settings from the SmartCart

SmartCart.hasAcceptedTermsboolean

Checks if the user has accepted the terms and conditions

SmartCart.hasCheckoutButtonboolean

Checks if the checkout button is enabled

SmartCart.hasContinueShoppingButtonboolean

Checks if the Continue Shopping button is enabled

SmartCart.hasPrePurchaseboolean

Returns true if there is a pre-purchase pop-up widget enabled

SmartCart.hasShopPayButtonboolean

Checks if the Shop Pay button is enabled

SmartCart.hasTermsEnabledboolean

Determines if the terms and conditions are enabled in settings

SmartCart.hasViewCartButtonboolean

Checks if the View Cart button is enabled

SmartCart.installmentsEnabledboolean

Returns true if the payment installments indicator text is enabled

SmartCart.installmentsMessagestring

Returns the payment installments indicator text

SmartCart.manageAcceleratedCheckoutvoid

Manages the Accelerated Checkout feature

SmartCart.prePurchaseWidgetIdstring

Returns the pre-purchase pop-up widget ID

SmartCart.renderPayPalButton

Conditionally renders a paypal button if the PayPal iFrame is not rendered

SmartCart.shopPayCheckoutvoid

Performs the Shop Pay checkout process

SmartCart.shopPaySvg : string

SVG code for the Shop Pay icon.

SmartCart.updateTermsCheckvoid

Update the terms checkbox status

SmartCart.viewCart

Navigates to the Shopify Cart Page

SmartCart.viewCartLabelstring

Gets the label for the View Cart button

SmartCart.adjustPreviewButtonsvoid

Updates the Accelerated Checkout buttons for previewing in the Admin.

ParamTypeDescription
settingsobjectSmart Cart settings

SmartCart.appendAcceleratedCheckoutvoid

Appends the '.additional-checkout-buttons' element to the SmartCart flyout

SmartCart.checkoutvoid

Performs the checkout process

SmartCart.checkoutLabelstring

Gets the label for the checkout button

Returns: string - The label for the checkout button (HTML content)

SmartCart.clearAcceleratedCheckoutvoid

Removes the '.additional-checkout-buttons' element from the SmartCart flyout

SmartCart.continueShoppingLabelstring

Get the label for the Continue Shopping button

Returns: string - The label for the Continue Shopping button

SmartCart.getAdditionalCheckoutButtonsboolean | object

Checks for the existence of the '.additional-checkout-buttons' element, which is used by the 'rebuy-smartcart-extensions.liquid' snippet

Returns: boolean | object - returns false otherwise buttonContainers, buttonContainer, buttonList, buttonListItems.

ParamTypeDescription
parentElementDOM Element

SmartCart.getCheckoutSettingsobject

gets the checkout settings from the SmartCart

Returns: object - The checkout settings object

SmartCart.hasAcceptedTermsboolean

Checks if the user has accepted the terms and conditions

Returns: boolean - True if the user has accepted the terms, otherwise false

SmartCart.hasCheckoutButtonboolean

Checks if the checkout button is enabled

Returns: boolean - True if the checkout button is enabled, otherwise false

SmartCart.hasContinueShoppingButtonboolean

Checks if the Continue Shopping button is enabled

Returns: boolean - True if the Continue Shopping button is enabled, otherwise false

SmartCart.hasPrePurchaseboolean

Returns true if there is a pre-purchase pop-up widget enabled

SmartCart.hasShopPayButtonboolean

Checks if the Shop Pay button is enabled

Returns: boolean - True if the Shop Pay button is enabled, otherwise false

SmartCart.hasTermsEnabledboolean

Determines if the terms and conditions are enabled in settings

Returns: boolean - True if terms and conditions are enabled, otherwise false

SmartCart.hasViewCartButtonboolean

Checks if the View Cart button is enabled

Returns: boolean - True if the View Cart button is enabled, otherwise false

SmartCart.installmentsEnabledboolean

Returns true if the payment installments indicator text is enabled

SmartCart.installmentsMessagestring

Returns the payment installments indicator text

Returns: string - HTML

SmartCart.manageAcceleratedCheckoutvoid

Manages the Accelerated Checkout feature

SmartCart.prePurchaseWidgetIdstring

Returns the pre-purchase pop-up widget ID

SmartCart.renderPayPalButton

Conditionally renders a paypal button if the PayPal iFrame is not rendered

SmartCart.shopPayCheckoutvoid

Performs the Shop Pay checkout process

SmartCart.shopPaySvg : string

SVG code for the Shop Pay icon.

SmartCart.updateTermsCheckvoid

Update the terms checkbox status

SmartCart.viewCart

Navigates to the Shopify Cart Page

SmartCart.viewCartLabelstring

Gets the label for the View Cart button

Returns: string - The label for the View Cart button