-
-
Save basilkhan05/7e37a71e5900235d114e765cd7ca20e5 to your computer and use it in GitHub Desktop.
Liquid template to add bundle details to products in Shopify (Simple Bundles)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% assign current_variant = product.selected_or_first_available_variant %} | |
{% assign bundled_variants = current_variant.metafields.simple_bundles.bundled_variants.value %} | |
{% unless bundled_variants == blank %} | |
<div class="product__description rte"> | |
<p>This bundle includes:</p> | |
<ul> | |
{% for bundled_variant in bundled_variants %} | |
<li> | |
{{ bundled_variant.quantity_in_bundle }} x | |
{{ bundled_variant.product_title }} | |
{% unless bundled_variant.variant_title == 'Default Title' %} | |
({{ bundled_variant.variant_title }}) | |
{% endunless %} | |
</li> | |
{% endfor %} | |
</ul> | |
</div> | |
{% endunless %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment