Skip to content

Instantly share code, notes, and snippets.

@svaustin66
Created July 20, 2022 19:16
Show Gist options
  • Save svaustin66/b8e9e2e031490bfadccce59c0a86c3ed to your computer and use it in GitHub Desktop.
Save svaustin66/b8e9e2e031490bfadccce59c0a86c3ed to your computer and use it in GitHub Desktop.
Example of placement of the snippet in the cart files.
<div class="cart__subtotal-container cart__row">
<div class="cart__row-description">
<p class="h3">{{ 'cart.general.subtotal' | t }}:</p>
</div>
<p class="h3 cart__subtotal">
<span class="money">
{%
render 'price-element',
price: cart.total_price
%}
</span>
</p>
</div>
{% render 'cart-automatic-discounts' %}
{% comment %}
{% if section.settings.display_savings and total_saving > 0 %}
<div class="cart__total-savings cart__row">
<div class="cart__row-description">
<p class="cart">{{ 'layout.general.savings' | t }}:</p>
</div>
<p class="cart__total-discount">
<span class="money">
{% assign total_savings = total_saving | plus: cart.total_discount %}
{%
render 'price-element',
price: total_savings
%}
</span>
</p>
</div>
{% endif %}
{% endcomment %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment