Instructions

The instructions assume version 10.0.2 of the theme is used.
If you are using a different version or a customized version of the theme, the line numbers and locations where code must be added may be different.

Quick reference: product pages

Liquid file(s)

  • product-template.liquid

Code to include

limoniapps-discountninja-productprice

To be added here:

Quick reference: Collection pages

Liquid file(s)

  • product-grid-item.liquid

Code to include at the start of the file

{%- assign limoniapps-discountninja-collections = "" -%}
{%- for collection in product.collections -%}
{%- assign limoniapps-discountninja-collections = limoniapps-discountninja-collections | append: collection.handle | append: "," -%}
{%- endfor -%}

Code to include at the end of the top level div element

data-limoniapps-discountninja-product-handle="{{ product.handle }}" data-limoniapps-discountninja-product-price="{{ product.price_min }}" data-limoniapps-discountninja-product-compareatprice="{{ product.compare_at_price_max }}" data-limoniapps-discountninja-product-collections="{{ limoniapps-discountninja-collections }}"

Code for the price section

<span class="limoniapps-discountninja-productprice">
</span>

Add the first fragment before the {% if featured.price_varies %} line.
Add the second fragment before the </p> element.

Quick reference: Cart page

Liquid file(s)

  • cart-template.liquid

Code for the root

limoniapps-discountninja-cart-root

Add it to the class attribute of the form

Code for the cart item

limoniapps-discountninja-cart-item
<span class="limoniapps-discountninja-cart-item-variant" style="display:none;">{{item.variant.id}}</span>

Add the first fragment to the class attribute of the first div in the for loop. Add the second code fragment on the line below that:

Code for the product comment

<div class="limoniapps-discountninja-cart-item-product-comment"></div>

Add it on a line above the custom product options section:

Code for the price section

limoniapps-discountninja-cart-item-product-price
limoniapps-discountninja-cart-item-line-price
limoniapps-discountninja-cart-item-line-comment

Add the first fragment as a class of the span element that contains the item.price.
Add the second fragment to the span that contains the item.line_price.
Add the third fragment on the line below the latter span:

Code for the subtotal section

limoniapps-discountninja-cart-subtotal-price
<div class="limoniapps-discountninja-cart-subtotal-comment"></div>

Add the first fragment as a class of the span element that contains the cart.total_price.
Add the second fragment on the line below that span:

That's it!

Did this answer your question?