Shopify collection ordering

There is no way to order collections in Shopify without using a manually defined LinkList, which can’t be exported via API or saved in themes. It’s always admin configured.

An alternative is a method to hard code collection handles, then iterate through all collections, only pulling matching collections handles.

It may "feel" inefficient, but Shopify pages are massively cached, and a few for loops are the least of our problems. Unless we have impossibly more collections.

{% assign collection_handles = 'sport,casual,dress,bespoke' | split: "," %}

{% for collection_handle in collection_handles %}
{% for collection in collections %}
{% if collection.handle == collection_handle %}
{{ collection.title }}

2 thoughts on “Shopify collection ordering

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s