Sale price
€0,00
Regular price
€1.000,00
To display all metaobject entries on your Shopify site:
-
Go to Online Store > Themes > Actions > Edit code.
-
In Templates, create page.metaobjects-list.liquid with this code (replace custom.your_metaobject_type with your metaobject's namespace.type):
<div class="metaobjects-list"> {% assign mo_def = shop.metaobjects.custom.your_metaobject_type %} {% for entry in mo_def.values %} <a href="/pages/{{ mo_def.type_handle }}--{{ entry.handle }}"> {{ entry.title.value }} </a> {% endfor %} </div> -
Create a page in Online Store > Pages, assign the metaobjects-list template.
-
Link the page in your navigation.
This loops up to 50 entries; for more, use the Storefront API.
— Make it into a block with configurable fields for reuse