--- url: /reference/items/FetchShopifySection/examples.md --- # Examples ::: tip These examples run against a Shopify storefront using the [Section Rendering API](https://shopify.dev/docs/api/ajax/section-rendering), so they are shown as code rather than live playgrounds. See the [`Fetch` examples](../Fetch/examples.md) for runnable demonstrations of the inherited behaviour. ::: ## Sorting a collection Refresh the product grid and the results count when the customer picks a sort order. The `href` keeps the section IDs out of it, so it stays a working link without JavaScript. ::: code-group ```liquid [collection.liquid] Sort by price {% comment %} `{% section %}` already outputs the `shopify-section-*` wrapper matched by id. {% endcomment %} {% section 'main-collection-product-grid' %} {% section 'collection-results-count' %} ``` ```ts [app.ts] import { registerComponent } from '@studiometa/js-toolkit'; import { FetchShopifySection } from '@studiometa/ui'; registerComponent(FetchShopifySection); ``` ::: ## Faceted filtering with a form Use a `