Skip to content

Instantly share code, notes, and snippets.

@anova
Created January 20, 2025 08:28
Show Gist options
  • Save anova/4a5ed437b2e69501da632b76fe912bff to your computer and use it in GitHub Desktop.
Save anova/4a5ed437b2e69501da632b76fe912bff to your computer and use it in GitHub Desktop.
Shopify Pinterest CSV feed template. In theme-name\templates\ folder.
{% layout none -%}"id","item_group_id","title","description","link","image_link","price","availability","condition"{{- '' }}
{%- paginate collections.all.products by 2000 -%}
{%- for product in collections.all.products -%}
{%- for variant in product.variants -%}
"{{ variant.id }}","{{ product.id }}","{{ product.title | strip_html | strip_newlines | escape -}}{%- if product.variants.size > 1 %} - {{ variant.title | strip_html | strip_newlines | escape }}{% endif %}","{{- product.description | strip_html | strip_newlines -}}","{{ shop.url -}}{{- variant.url }}","https:{{- variant.featured_image | default: product.featured_image | img_url: '400x' -}}","{{ product.price | money_without_currency | replace: "TL", "TRY" }}","{%- if product.available -%}in stock{%- else -%}out of stock{%- endif -%}","new"{{- '' }}
{%- endfor -%}
{%- endfor -%}
{%- endpaginate -%}
{% comment %}
https://auglio.com/en/knowledge-base/article/20-xml-product-feed-for-shopify-stores
{% endcomment %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment