Guides

Polaris Components

Overview and quick start guide for Shopify Polaris and App Bridge UI components.

Overview

This module provides Vue wrapper components for Shopify Polaris web components. Use the Sh-prefixed wrappers instead of raw s-* web components — they provide typed props with autocomplete, v-model support for form components, and work seamlessly with Vue's reactivity system.

All Sh* components are auto-imported — no manual imports needed.

For detailed props, events, and slots of each component, see the Polaris Components reference.

Component Prefix

All components use a configurable prefix (default: Sh). You can change it via the componentPrefix module option:

// nuxt.config.ts
export default defineNuxtConfig({
  shopify: {
    componentPrefix: 'Shopify' // <ShopifyButton>, <ShopifyApp>, etc.
  }
})

The examples below use the default Sh prefix.

Basic Example

<template>
  <ShPage heading="Products">
    <ShStack gap="base">
      <ShButton variant="primary" @click="save">Save</ShButton>
      <ShButton @click="cancel">Cancel</ShButton>
    </ShStack>

    <ShBanner heading="Welcome" tone="info" dismissible>
      Start by adding your first product.
    </ShBanner>

    <ShTextField
      v-model="title"
      label="Product title"
      placeholder="Enter product title"
    />

    <ShSelect
      v-model="status"
      label="Status"
      :options="[
        { label: 'Active', value: 'active' },
        { label: 'Draft', value: 'draft' }
      ]"
    />
  </ShPage>
</template>

App Components

<ShApp>

Wrap your app pages with <ShApp> to automatically render the App Bridge navigation menu from your module config. See ShApp reference.

layouts/default.vue
<template>
  <ShApp>
    <slot />
  </ShApp>
</template>

<ShLoadingIndicator>

Bridges the Nuxt loading indicator with the Shopify Admin loading bar. See ShLoadingIndicator reference.

<template>
  <ShLoadingIndicator>
    <ShPage title="Products">
      <!-- content -->
    </ShPage>
  </ShLoadingIndicator>
</template>

Available Components

Each Polaris component maps to its web component counterpart (e.g., <ShButton><s-button>). Browse the full reference with props, events, and slots:

CategoryComponentsReference
LayoutShPage, ShBox, ShStack, ShGrid, ShGridItem, ShSection, ShDividerLayout
ActionsShButton, ShButtonGroup, ShClickable, ShLinkActions
FormsShTextField, ShNumberField, ShEmailField, ShPasswordField, ShUrlField, ShMoneyField, ShColorField, ShDateField, ShTextArea, ShSelect, ShCheckbox, ShSwitch, ShChoiceList, ShChoice, ShSearchField, ShDropZone, ShColorPicker, ShDatePickerForms
FeedbackShBanner, ShBadge, ShSpinner, ShTooltipFeedback
NavigationShAppNav, ShMenu, ShOption, ShOptionGroup, ShPopoverNavigation
DataShTable, ShTableHeader, ShTableHeaderRow, ShTableBody, ShTableRow, ShTableCellData
ContentShText, ShHeading, ShParagraph, ShIcon, ShImage, ShThumbnail, ShAvatar, ShChip, ShClickableChip, ShListItem, ShOrderedList, ShUnorderedListContent
OverlaysShModal, ShQueryContainerOverlays
App Bridge UIShUiModal, ShUiTitleBar, ShUiSaveBar, ShUiNavMenuApp Bridge UI

Polaris Modal (ShModal)

ShModal wraps the Polaris <s-modal> component — it renders inside your app's iframe. Open and close it using commandFor / command attributes:

<template>
  <ShButton command-for="my-modal" command="--show">Open</ShButton>

  <ShModal id="my-modal" heading="Confirm action">
    <ShParagraph>Are you sure?</ShParagraph>

    <ShButton slot="secondary-actions" command-for="my-modal" command="--hide">
      Cancel
    </ShButton>
    <ShButton
      slot="primary-action"
      variant="primary"
      command-for="my-modal"
      command="--hide"
    >
      Confirm
    </ShButton>
  </ShModal>
</template>
You can also control <s-modal> programmatically: shopify.modal.show('my-modal'), shopify.modal.hide('my-modal'), shopify.modal.toggle('my-modal').
ShModal is not the same as the App Bridge <ui-modal> which renders outside the iframe. If you need the App Bridge modal, use <ShUiModal>.

App Bridge UI Components (ShUi*)

In addition to the Polaris Sh* components (rendered inside your iframe), the module provides ShUi* wrappers for App Bridge UI web components (ui-*). These render outside the app iframe in the Shopify Admin shell.

These are the Vue replacements for @shopify/app-bridge-react components (Modal, TitleBar, SaveBar, NavMenu).

Polaris (Sh*) vs App Bridge (ShUi*)

Polaris (Sh*)App Bridge (ShUi*)
HTML elements<s-button>, <s-modal>, etc.<ui-modal>, <ui-title-bar>, etc.
Renders inYour app's iframeShopify Admin (outside the iframe)
Use forIn-app UI: forms, tables, buttons, layoutAdmin-level chrome: page title, modals overlaying the admin, save bar, navigation
Controlled viaProps, slots, command/commandForuseAppBridge() API (shopify.modal.show(id), etc.)

For detailed props, events, and usage examples, see the individual component pages:

All ShUi* components can be controlled programmatically via the shopify global (accessed with useAppBridge()):

APIDescriptionDocs
shopify.modalShow, hide, and toggle modals by IDModal API
shopify.saveBarShow, hide, toggle save bars and prompt leave confirmationSave Bar API
shopify.toast.show(message)Show toast notificationsToast API
shopify.loading.show() / .hide()Control the admin loading barLoading API
shopify.resourcePicker()Open product/collection/variant pickersResource Picker API
shopify.intents.navigate()Launch native Shopify admin workflowsIntents API

See the full list at App Bridge APIs and web methods.

© 2026 KiriminAja. Polaris and Shopify are trademarks of Shopify Inc.

KiriminAja not affiliated with Shopify.