Cart Widget Configuration Reference

Complete reference for all Weevio Cart Widget configuration options, default values, and example setups.

The Cart Widget is configured through the window.weevioCartConfig object in your Liquid snippet. This page documents every available option, its default value, and how to use it.

Configuration Options

Required Settings

These values must be set for the widget to function.

OptionTypeDescription
shopifyDomainstringYour Shopify store domain, e.g., 'your-store.myshopify.com'. Do not include https://.
teamIDstringYour Weevio Team ID. Provided by Weevio during onboarding.
baseURLstringWeevio API base URL. Provided by Weevio during onboarding.
shippingEtasPlanstringYour shipping ETAs plan level. Provided by Weevio during onboarding.
widgetTypestringMust be set to 'cart'. Do not change this value.

Feature Toggles

Control which features are active in the widget.

OptionTypeDefaultDescription
enableWidgetbooleantrueMaster toggle for the entire widget. Set to false to disable without removing the code.
enableDeliveryEtasbooleantrueShow shipping delivery estimates for each cart item.
enableLocalPickupbooleanfalseShow local pickup availability for each cart item. Requires store locations configured in Weevio Cloud.
enableLoadingTextbooleantrueWhen true, shows animated loading text while fetching estimates. When false, shows a skeleton loader instead.

Display Customization

Adjust how estimates are presented to customers.

OptionTypeDefaultDescription
fontSizestring'15px'Font size for all estimate messages. Accepts any CSS value: '12px', '1rem', 'small', etc.
verboseTextbooleanfalseWhen true, shows detailed messages (e.g., "Typically delivers to 10001 in 3 to 5 business days."). When false, shows concise messages (e.g., "Est. delivery to 10001 in 3 to 5 days").
useStaticZipCodestring or falsefalsePre-fill a zip code so estimates display immediately without customer input. Set to a 5-digit zip code string (e.g., '10001') or false to require customer entry.
toastBottomOffsetstring'0px'CSS offset from the bottom of the viewport for error toast notifications. Increase this value if your theme has a sticky footer or bottom banner that would cover the notifications (e.g., '60px').

CSS Selector Overrides

Override the default CSS selectors if your Shopify theme uses different markup than the Dawn theme.

OptionTypeDefaultDescription
cartItemsSelectorstring'.cart-item__details'CSS selector that matches each cart line item element. The widget injects shipping estimates next to each matched element.
zipcodeAndDisclaimerSelectorstring'form[action="/cart"].cart__contents.critical-hidden'CSS selector for the container where the zip code prompt and disclaimer are rendered.

Note:

The default CSS selectors work with Shopify's Dawn theme and similar themes. If you use a custom or third-party theme, you may need to inspect your cart page HTML and provide custom selectors. See the Troubleshooting page for guidance.

Configuration Examples

Basic Setup

A minimal configuration for stores that want delivery estimates only:

window.weevioCartConfig = {
    shopifyDomain: 'mystore.myshopify.com',
    enableWidget: true,
    enableDeliveryEtas: true,
    enableLocalPickup: false,

    widgetType: 'cart',
    teamID: 'your-team-id',
    baseURL: 'https://api.weevio.com',
    shippingEtasPlan: 'premium'
};

Delivery Estimates with Local Pickup

Enable both delivery estimates and local pickup availability:

window.weevioCartConfig = {
    shopifyDomain: 'mystore.myshopify.com',
    enableWidget: true,
    enableDeliveryEtas: true,
    enableLocalPickup: true,
    verboseText: true,

    widgetType: 'cart',
    teamID: 'your-team-id',
    baseURL: 'https://api.weevio.com',
    shippingEtasPlan: 'premium'
};

Regional Store with Default Zip Code

For stores that primarily serve a specific region, pre-fill the zip code so estimates appear immediately:

window.weevioCartConfig = {
    shopifyDomain: 'mystore.myshopify.com',
    enableWidget: true,
    enableDeliveryEtas: true,
    enableLocalPickup: true,
    useStaticZipCode: '90210',
    verboseText: false,
    fontSize: '14px',

    widgetType: 'cart',
    teamID: 'your-team-id',
    baseURL: 'https://api.weevio.com',
    shippingEtasPlan: 'premium'
};

Note:

Even with a static zip code, customers can still click the displayed zip code to change it and see estimates for their actual location.

Custom Theme with Adjusted Selectors

For themes that use different CSS classes for cart items:

window.weevioCartConfig = {
    shopifyDomain: 'mystore.myshopify.com',
    enableWidget: true,
    enableDeliveryEtas: true,
    enableLocalPickup: false,
    enableLoadingText: false,
    toastBottomOffset: '60px',
    cartItemsSelector: '.custom-cart-item',
    zipcodeAndDisclaimerSelector: '.cart-footer-custom',

    widgetType: 'cart',
    teamID: 'your-team-id',
    baseURL: 'https://api.weevio.com',
    shippingEtasPlan: 'premium'
};

Message Examples

The table below shows the messages displayed for different scenarios in each text mode.

Delivery Estimates

ScenarioVerboseConcise
With zip codeTypically delivers to 10001 in 3 to 5 business days.Est. delivery to 10001 in 3 to 5 days
Without zip codeTypically delivers in 3 to 5 business days.Est. delivery in 3 to 5 days

Local Pickup

ScenarioVerboseConcise
Fully availableLocal pick up available same business day.Local pickup available today
Partially availableLocal pick up partially available same business day. 2 available now.2 available for local pickup
Warehouse-to-storeLocal pick up available in 3 to 5 business days.Local pickup available in 3 to 5 days

Zip Code Behavior

The Cart Widget shares zip code storage with the Product Page Widget through the browser's localStorage. This means:

  • If a customer enters their zip code on a product page, the Cart Widget uses it automatically
  • If a customer enters their zip code on the cart page, the Product Page Widget uses it on subsequent product pages
  • The zip code persists across page navigations within the same browser session
  • Customers can change their zip code at any time by clicking the displayed zip code value

Note:

Zip codes must be exactly 5 digits (US format). The widget validates input and will not accept invalid formats.

Need Help?

For assistance, please send a message to our Support page.