{% for collection in collections %}
{% for product in collections.collection.handle.products %}
{{ product.name }}
{% endfor %}
{% endfor %}
I am building templates in Shopify which show all products I am using the cheat sheet example to get all product but it is working like this one.
This is not working in my liquid page I am using another method to get the collection name and show all product with this collection one loop is to get the collection name one is to get the product list related to that collection.
2
Answers
There is a collection called "all" that has all your products in it. It is automatically created and can be override when you create a "all" collection with the same name/url.
More Infor here on the All collection
For nested looping in Shopify collection and product use this one:
Using this you can get all details of collection and list out the all product of this collections.
This code is working and currently use this code in my store also.