Shopify if statement in for loop
I have some variants I'm looping over and then assigning the whole thing to a variable {% if settings.limit_quantity or settings.display_inventory_left %} {% assign variantInventory = data-variant-inventory:'[ {% for v in product.variants %} { "id":{{ v.id }}, "inventory_quantity":{{v.inventory_quantity}}, "inventory_management":"{{- v.inventory_management…