Bold Bundles requires our Liquid code in order to run correctly on your store. The code installation ensures that your pricing will appear on your product pages and that your customer's selections will appear correctly on both the cart and checkout pages of your store.
Before installing the Liquid code, it is recommended to create a duplicate version of your Shopify theme to ensure you have a copy without our code installation.
Alert
This article has installation instructions for all three versions of Bold Bundles. It is recommended to determine which version is installed on your store before proceeding.
When you install the Bold Bundles app to your store, you are able to navigate to our Liquid install area within the app. This can be found within the side bar, Need Help? > Liquid Installation section.
Selecting the Begin automatic update option will allow you to choose the theme on your store that you would like to complete the automatic code installation on for Bold Bundles.
When selecting which theme to update, there will be a check box that says, "I have created a backup of this theme".
We recommend creating a duplicate version of your Shopify theme to ensure you have a copy without the Bold code installed.
Once the checkbox is selected to confirm you have a back up version of your theme, you will be able to proceed with the code installation.
Troubleshooting Pro-Tip
Some themes are too complex for the installation tool, which may cause it to attempt the installation indefinitely. Should this occur, please request an Expert Install.
Alert
To maintain the security of your Shopify account, we ask that you do not proactively send us a Staff Account invite for access to your shop. Instead, our team will request Collaborator access to your shop.
This option creates a ticket with our installation team, and schedules your store for a manual installation completed by our experts. By selecting this option, you will be asked to confirm which theme you would like this code installation to be completed on.
All of these requests are completed manually on a rotational basis and will be completed as soon as possible.
- From within Bold Bundles, navigate to Help > Liquid Installation.
- Under the Expert theme update service, select Begin update.
- On the bottom left corner, select which theme you would like the installation completed on.
- Select Submit Request.
Manual Installation
V1 & V2 Code Install Instructions (Vintage Themes)
Alert
This installation will not work for themes using render tags. You will need to upgrade to Version 3 of Bold Bundles, or use a theme that can work with include tags.
Please visit Shopify Render Tag Adjustments for more information.
This installation allows the bundles to appear on the product page and discount correctly on the product, cart and checkout page.
Step 1: Add Snippet Files
- Duplicate themes to create a backup copy.
- From the Shopify admin, select Online Store.
- Select Actions.
- Select Edit code.
- Under Snippets, find these files:
- bold-common.liquid
- bold-includes.liquid
- bold-product.liquid
- bold-variant.liquid
- shappify-bdl-load-bundle.liquid
- bold-bundles.css
- For any that don't exist:
- Select Add a new snippet.
- Enter the correct snippet name.
- Select Create snippet.
- Copy and paste the code found in each of these links into their respective files:
- bold-common.liquid
- bold-includes.liquid
- bold-product.liquid
- bold-variant.liquid
- shappify-bdl-load-bundle.liquid
- bold-bundles.css
- Select Save.
- Repeat steps 6.1 – 6.5 for each missing snippet file.
Step 2: Edit collection.liquid
-
Under Templates, select collection.liquid.
Note: If your theme contains sections, you may need to open collection-template.liquid under Sections instead.
-
Find each instance of:
{% for product in collection.products %}
Note: If you can't find this code, look to see if the theme has a product-loop.liquid. Can't find this code?
-
Copy and paste:
{% include 'bold-product' with product, hide_action: 'skip' %}
on the line below each instance.
- Select Save.
Step 3: Edit index.liquid
-
Under Templates, select index.liquid.
Note: If your theme contains Sections, you may need to look under Sections instead. The file may be named: featured-products.liquid, home-collection.liquid, home-featured-products.liquid, featured-row.liquid, simple-collection.liquid, featured-collection.liquid, home-tab.liquid, home-big-product.liquid, index-products.liquid or tabs-collection.liquid.
-
Find each instance of:
{% for product in collection.products %}
Note If you can't find this code, look to see if the theme has a product-loop.liquid. Can't find this code?
-
Copy and paste:
{% include 'bold-product' with product, hide_action: 'skip' %}
on the line below each instance.
- Select Save.
Step 4: Edit related-products.liquid
- Under Snippets, select related-products.liquid.
-
Find each instance of:
{% for product in collection.products %}
Note If you can't find this code, look to see if the theme has a product-loop.liquid. Can't find this code?
-
Copy and paste:
{% include 'bold-product' with product, hide_action: 'skip' %}
on the line below each instance.
- Select Save.
Step 5: Edit search.liquid
- Under Templates, select search.liquid.
-
Find each instance of:
{% for item in search.results %}
-
Copy and paste:
{% include 'bold-product' with item, hide_action: 'skip' %}
on the line below each instance.
- Select Save.
Step 6: Edit product.liquid
- Under Templates, select product.liquid.
-
Add this code to the top of the file:
Note: If your theme contains Sections, you may have to make these changes in product-template.liquid under Sections.
{% include 'bold-product' with product, hide_action: 'break' %}{% if bold_hidden_product %}{% break %}{%endif %}
-
Find each instance of:
{% for variant in product.variants %}
-
Copy and paste:
{% include 'bold-variant' with variant, hide_action: 'skip' %}
on the line below each instance.
Note: If your theme uses swatches, where variants are shown as buttons instead of through a drop-down menu, this code will also need to be added to a snippet file, usually named swatch.liquid or product-swatch.liquid.
-
Find each instance of:
product.variants.size
Note: If you can't find this in the product.liquid file, then check the snippets folder for a product-form.liquid or short-form.liquid file and look for the code in there.
-
Replace each instance with:
bold_variants_size
-
Find each instance of:
{{ product | json }}
Note: If you can't find {{ product | json }} in those files, try searching for it in the theme.liquid file. If it's not in the product.liquid or theme.liquid file, then this can be skipped.
-
Replace each instance with:
{% include 'bold-product', output: 'json' %}
-
Add this code where you would like the product bundle to display on the product page.
Note: This code cannot be within the form tags. We recommend adding it either after the </form> tag or just before the code that outputs the related products. If you can't find the </form> tag in the product.liquid file, check the Snippets folder for a product-form.liquid or short-form.liquid file and look for the code in there.
{% unless bundle_loaded == 'true' %} {% include 'shappify-bdl-load-bundle' %} {% assign bundle_loaded = 'true' %} {% endunless %}
- Select Save.
Step 7: Edit bold-includes.liquid
- Under Snippets, select bold-incudes.liquid.
- Copy and paste this code in the bottom of the file.
{{ 'https://bundles.boldapps.net/js/bundles.js' | script_tag }} {{ 'bold-bundles.css' | asset_url | stylesheet_tag }}
- Select Save.
Step 8: Edit theme.liquid
- Under Layout, select theme.liquid.
- Copy and paste this code directly above the </head> tag:
{% include 'bold-common' %}
{% include 'bold-includes' %} - Select Save.
Step 9: Edit cart.liquid
-
Under Templates, select cart.liquid.
Note: If your theme contains Sections, you may have to look for this code under Sections in cart-template.liquid instead.
-
Find every occurrence of code similar to:
On newer themes, it will be:{{ item.price | money }}
{{ item.final_price | money }}
Note: The item price display can vary by theme but should be similar to this.
-
Copy and paste this code directly before that line:
<span class=“Bold-theme-hook-DO-NOT-DELETE bold_cart_item_price” data-item-key=“{{item.key}}” style=“display:none !important;“></span>
-
Find every occurrence of code similar to:
On newer themes, it will be:{{ item.line_price | money }}
{{ item.final_line_price | money }}
Note: The item line price display can vary by theme but should be similar to this.
-
Copy and paste this code directly before that line:
<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_item_total" data-item-key=”{{item.key}}" style="display:none !important;"></span>
-
Find every occurrence of code similar to:
{{ cart.total_price | money }}
Note: The cart total price display can vary by theme but should be similar to this.
-
Copy and paste this code directly above that line:
<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_total" style="display:none !important;"></span>
-
Find the section that starts similar to:
{% for p in item.properties %}
-
Replace the entire section with:
<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_item_properties" style="display:none !important;"></span> {% assign propertySize = item.properties | size %} {% if propertySize > 0 %} {% for p in item.properties %} {% assign first_character_in_key = p.first | truncate: 1, '' %} {% unless p.last == blank or first_character_in_key == '_' %} {{ p.first }}: {% if p.last contains '/uploads/' %} <a href="{{ p.last }}">{{ p.last | split: '/' | last }}</a> {% else %} {{ p.last }} {% endif %} {% endunless %} {% endfor %} {% endif %}
- Select Save.
Step 10: Update Pricing Code
Updates need to be done on all theme files that output product prices on the store. The number and name of these files will vary from theme to theme. Generally, 3-5 files will need to be updated.
These control the price fields on the product, collection, search, related products, and home pages.
It's important that each theme file that outputs a price be modified. This is to ensure the correct pricing always shows for your customers.
Note: This will require you to go back and edit multiple files within your theme's Liquid coding.
Go through the list of files one at a time and reference your theme's files to see if that particular file exists in your theme. Not all of these files will exist in a given theme.
- Templates: All themes should contain these files. If your theme is using Sections, these files will be located within the Sections folder as *-template.liquid files.
- product.liquid
- index.liquid
- collection.liquid
- search.liquid
- Snippets: Any given theme should typically have several of these files.
- product-block.liquid
- product-card.liquid
- product-form.liquid
- product-grid-collage.liquid
- product-grid-item-category.liquid
- product-grid-item.liquid
- product-list-item.liquid
- product-listing.liquid
- product-loop.liquid
- product-single.liquid
- product-thumbnail.liquid
- product.liquid
- related-products.liquid
- search-result-grid.liquid
- search-result.liquid
- search.liquid
- short-form.liquid
- snippet-product-item.liquid
- Assets: No changes necessary.
When you've gone through the list, this step will be complete.
Look for each of these ... | ... and replace all instances with this code |
---|---|
product.price | bold_price |
product.price_min | bold_price_min |
product.price_max | bold_price_max |
product.price_varies | bold_price_varies |
product.compare_at_price | bold_compare_at_price |
product.compare_at_price_min | bold_compare_at_price_min |
product.compare_at_price_max | bold_compare_at_price_max |
product.compare_at_price_varies | bold_compare_at_price_varies |
product.selected_or_first_available_variant | bold_selected_or_first_available_variant |
product.variants.first | bold_selected_or_first_available_variant |
product.variants[0] | bold_selected_or_first_available_variant |
Not all of these will appear in a given file, but the ones that do appear in a file may appear a few times.
If the file has none of these, then select the item.price tab.
Look for each of these ... | ... and replace all instances with this code |
---|---|
item.price | bold_price |
item.price_min | bold_price_min |
item.price_max | bold_price_max |
item.price_varies | bold_price_varies |
item.compare_at_price | bold_compare_at_price |
item.compare_at_price_min | bold_compare_at_price_min |
item.compare_at_price_max | bold_compare_at_price_max |
item.compare_at_price_varies | bold_compare_at_price_varies |
item.selected_or_first_available_variant | bold_selected_or_first_available_variant |
item.variants.first | bold_selected_or_first_available_variant |
item.variants[0] | bold_selected_or_first_available_variant |
Not all of these will appear in a given file, but the ones that do appear in a file may appear a few times.
If you found and replaced some of the above, then select the Files to Update tab and continue down the file list.
If the file has none of these, then bring up the file editor's search feature (CTRL+F), and do a search for .price and continue below.
If nothing is found after the search, or if you find variant.price, variant.price_min, variant.price_max or variant.price_varies, then nothing will need to be done with this file, and you can select the Files to Update tab and continue down the file list.
If something is found after the search, take note of what was found, and then select the Other tab.
Some files in some themes will use something other than product or item, and you'll need to change our code to work with what the file uses.
Example
IE. A file may use product-detail instead
To proceed, substitute * with whatever was before the .price when you searched in the previous section, then look for that code in the file and replace what you find with the app's code. It's not necessary to change anything with variant in it, such as variant.price.
Example
IE. If you found product-detail.price, then replace * with product-detail with each item below, then look for that code in the theme. For the first item, you'd look for product-detail.price, and if found, replace it with bold_price
Look for each of these ... | ... and replace all instances with this code |
---|---|
*.price | bold_price |
*.price_min | bold_price_min |
*.price_max | bold_price_max |
*.price_varies | bold_price_varies |
*.compare_at_price | bold_compare_at_price |
*.compare_at_price_min | bold_compare_at_price_min |
*.compare_at_price_max | bold_compare_at_price_max |
*.compare_at_price_varies | bold_compare_at_price_varies |
*.selected_or_first_available_variant | bold_selected_or_first_available_variant |
*.variants.first | bold_selected_or_first_available_variant |
*.variants[0] | bold_selected_or_first_available_variant |
Not all of these will appear in a given file, but the ones that do appear in a file may appear a few times.
When you're done with this file, select the File to Update tab and continue down the file list.
V3 Code Install Instructions (Vintage Themes)
Step 1: Add Snippet Files
- Duplicate themes to create a backup copy.
- From the Shopify admin, select Online Store.
- Select Actions.
- Select Edit code.
- Under Snippets and Assets, find these files:
- bold-bundles.css
- bold-common.liquid
- bold-includes.liquid
- bold-pr.liquid
- shappify-bdl-load-bundle.liquid
- For any that don't exist:
- Select Add a new snippet or Add a new asset.
- Enter the correct snippet name.
- Select Create snippet.
- Copy and paste the code found in each of these links into their respective files:
- bold-bundles.css
- bold-common.liquid
- bold-includes.liquid
- bold-pr.liquid
- shappify-bdl-load-bundle.liquid
- Select Save.
- Repeat steps 6.1 - 6.5 for each missing snippet file.
Step 2: Edit theme.liquid
- Under Layout, select theme.liquid.
- Copy and paste the following code below the {{ content_for_header }} line:
{%- render 'bold-pr' -%}
{%- render 'bold-common' -%}
{%- render 'bold-includes' -%} - Select Save.
Step 3: Add the Product Loop Code
Overview
Updates need to be done on all theme files that pull your product information to the cart. The number and name of these files will vary from theme to theme. Generally, 3-5 files will need to be updated.
It's important that each theme file that outputs a price be modified. This is to ensure the correct information always shows for your customers.
Note: This will require you to go back and edit multiple files within your theme coding.
Go through the list of files one at a time and reference your theme's files to see if that particular file exists in your theme. Not all of these files will exist in a given theme.
List of Theme Files to Update
- Templates: Themes should contain most of these files. If your theme is using "Sections", these files will be located within the "Sections" folder as *-template.liquid files.
- collection.liquid
- list-collections.liquid
- search.liquid
- Sections & Snippets: Any given theme should typically have a few of these files.
- collection-template.liquid
- featured-collection.liquid
- product-full.liquid
- product-loop.liquid
- product-recommendations.liquid
- product-slider.liquid
- related-products.liquid
Not all of these will appear in a given file, but the ones that do may appear several times.
Code Adjustments Required
Your theme's product loop code should look similar to this:
{% for product in collection.products %}
The following code should be inserted directly after each instance:
<script type="application/json" class="bold-product-json">{{ product | json }}</script>
In some cases, the product loop code may look slightly different:
{% for item in search.results %}
We then need to adjust the end of our Bold price code to include the loop's product reference:
Note: Visit Product Loop Code Variations for more information on what this coding may look like.
<script type="application/json" class="bold-product-json">{{ item | json }}</script>
Step 4: Update the Product Price Code
Overview
Updates need to be done on all theme files that output product prices on the store. The number and name of these files will vary from theme to theme. Generally, 3-5 files will need to be updated.
These control the price fields on the product, collection, search, related products, and home pages.
It's important that each theme file that outputs a price be modified. This is to ensure the correct pricing always shows for your customers.
Note: This will require you to go back and edit multiple files within your theme coding.
Go through the list of files one at a time and reference your theme's files to see if that particular file exists in your theme. Not all of these files will exist in a given theme.
List of Theme Files to Update
- Templates: Themes should contain most of these files. If your theme is using Sections, these files will be located within the Sections folder as *-template.liquid files.
- product.liquid
- index.liquid
- collection.liquid
- search.liquid
- Sections & Snippets: Any given theme should typically have a few of these files.
- featured-product.liquid
- product-card.liquid
- product-grid-item.liquid
- product-form.liquid
- product-template.liquid
- related-products.liquid
Code Adjustments Required
Your theme's product price code should look similar to this:
{{ product.price | money }}
The following code should be placed around each of these instances with the <span> tags wrapping this price code:
<span class="money" data-product-id="{{ product.id }}">{{ product.price | money }}</span>
In some cases, the product price code may look slightly different:
{{ item.price | money }}
The following code should still be placed around each of these instances with the <span> tags wrapping this price code:
Note: Visit Product Price Code Variations for more information on what this coding may look like.
<span class="money" data-product-id="{{ item.id }}">{{ item.price | money }}</span>
Step 5: Update the Cart Price Code
Overview
Updates need to be done to the cart files that pull your product price information to the cart. The number and name of these files will vary from theme to theme.
It's important that each theme file that pulls this price information be edited. This is to ensure the correct information always shows for your customers.
Note: This will require you to go back and edit multiple files within your theme coding.
Go through the list of files one at a time and reference your theme's files to see if that particular file exists in your theme. Not all of these files will exist in a given theme.
List of Theme Files to Update
- Templates: If your theme is using Sections, these files will be located within the Sections folder as *-template.liquid files.
- cart.liquid
- Sections & Snippets:
- cart-ajax.liquid
- cart-content.liquid
- cart-template.liquid
Code Adjustments Required
First, you'll need to find each instance of coding that looks similar to this:
{{ item.price | money }}
The following code should be placed around each of these instances with the <span> tags wrapping this code:
<span class="money" data-line-index="{{ forloop.index0 }}">{{ item.price | money }}</span>
Next you'll need to find each instance of coding that looks similar to this:
{{ item.line_price | money }}
The following code should be placed around each of these instances with the <span> tags wrapping this code:
<span class="money" data-line-total data-line-index="{{ forloop.index0 }}">{{ item.line_price | money }}</span>
Lastly, you'll need to find each instance of coding that looks similar to this:
{{ cart.total_price | money }}
The following code should be placed around each of these instances with the <span> tags wrapping this code:
<span class="money" data-cart-total>{{ cart.total_price | money }}</span>
Step 6: Place the Bundles Widget (optional)
In some cases, you may want to manually place where your Bold Bundles widget displays on the storefront.
To choose the placement of your widget, please follow these steps:
- Under Templates, select product.liquid.
Note: If your theme is using Sections, the contents for this file may be within product-template.liquid.
- Find where you want to place your widget in the code.
Note: Generally, most store owners will place just below your product page's </form> tag.
- Copy and paste the following code in your desired location:
{%- render 'shappify-bdl-load-bundle' -%}
- Select Save.
Step 7: Install the Ajax Scripts
Caution
Not all of the following coding snippets will need to be inserted into your theme. You will need to determine the function your theme uses to build your AJAX modals and install the appropriate coding from there. This section requires advanced knowledge of JavaScript and web coding to complete. If you are not comfortable with this, please contact our Merchant Success team for further assistance.
Overview
For themes that use AJAX functionalities, updates must be made to the JavaScript files that build these AJAX pages and/or modals. The file name and location of this code will vary from theme to theme.
Note: This is only required for themes that have AJAX functions.
These updates are done to ensure the correct product price displays every time it's shown on your storefront. This may require you to go back and edit multiple files in your theme coding.
List of Theme Files to Update
- Assets: Your theme may contain one or a few of these files. The required coding adjustment(s) are explained in the next section.
- ajax-cart.js.liquid
- ajaxify-cart.js.liquid
- ajaxify-shop.js.liquid
- ajaxify.js.liquid
- app.js
- apps.js
- atlantic.js* - Atlantic by Pixel Union
- colors-ajax-cart.js.liquid* - Colors by Small Victories
- ella.js* - Ella by Halo Themes
- empire.js* - Empire by Pixel Union
- functions.min.js
- handy.js* - Handy by Pixel Union
- jas_theme.min.js
- js_main.js
- main.js.liquid
- script.js.liquid
- script.min.js
- sections.js.liquid
- shop.js.liquid
- site.js.liquid
- superstore.js* - Superstore by Pixel Union
- theme.js
- theme.js.liquid
- theme.min.js
- timber.js.liquid
- vendor.min.js
* = Theme specific file. The theme name and developer are noted beside the file name.
Code Adjustments Required
Themes that pass cart objects between your regular cart and the AJAX modals will need to use our Cart Doctor function.
Most themes will use the function buildCart to show your products in their AJAX modals and pass this information between both areas.
You'll need to find where this code is in one of the above files, and paste the following code within this function:
// Bold:PRE
if (typeof window.BOLD !== 'undefined'
&& typeof window.BOLD.common !== 'undefined'
&& typeof window.BOLD.common.cartDoctor !== 'undefined') {
// NOTE: "cart" should be the variable containing the cart JSON data
cart = window.BOLD.common.cartDoctor.fix(cart);
}
// Bold:PRE
Some themes may use the function refreshCart to show your items in these modals.
You'll need to find where this code is in one of the above files, and paste the following code within this function:
// Bold:PRE
if (typeof window.BOLD !== 'undefined'
&& typeof window.BOLD.common !== 'undefined'
&& typeof window.BOLD.common.cartDoctor !== 'undefined') {
// NOTE: "cart" should be the variable containing the cart JSON data
cart = window.BOLD.common.cartDoctor.fix(cart);
}
// Bold:PRE
Themes that simply display the information from your cart in the AJAX modals will need to use our Event Emitter function.
Most themes will pull this information by using the getCartData function.
Note: If Bold Upsell's AJAX code is already installed on your theme, you do not need to install this code. It should already be contained in your theme files.
You'll need to find where this code is in one of the above files, and paste the following code within this function:
// Bold:PRE
if (window.BOLD && BOLD.common && BOLD.common.eventEmitter &&
typeof BOLD.common.eventEmitter.emit === 'function'){
BOLD.common.eventEmitter.emit('BOLD_COMMON_cart_loaded');
}
// Bold:PRE
Some themes will grab this information through the updateView function.
You'll need to find where this code is in one of the above files, and paste the following code within this function:
// Bold:PRE
if (window.BOLD && BOLD.common && BOLD.common.eventEmitter &&
typeof BOLD.common.eventEmitter.emit === 'function'){
BOLD.common.eventEmitter.emit('BOLD_COMMON_cart_loaded');
}
// Bold:PRE
Step 8: Edit bold-includes.liquid
- Under Snippets, select bold-includes.liquid.
- Copy and paste this code in the bottom of the file.
{{ 'https://bundles.boldapps.net/js/bundles.js' | script_tag }} {{ 'bold-bundles.css' | asset_url | stylesheet_tag }}
- Select Save.
Alert
Bundles V1 & V2 are not supported on themes that use render tags such as Online Store 2.0 themes. Please upgrade to Bundles V3. For more information on how to identify or change your Bundles version, please visit Bundles' Discount Methods and How to Switch.
If you require Bundles V2 and are using one of these themes but have had custom work to remove the render tag, please follow the instructions below.
V2 Code Install Instructions (Online Store 2.0 Themes)
This installation allows the bundles to appear on the product page and discount correctly on the product, cart and checkout page.
Step 1: Add Snippet and Asset Files
- Duplicate themes to create a backup copy.
- From the Shopify admin, select Online Store.
- Select Actions.
- Select Edit code.
- Under Snippets and Assets, find these files:
- bold-common.liquid
- bold-includes.liquid
- shappify-bdl-load-bundle.liquid
- bold-variant.liquid
- bold-product.liquid
- bold-bundles.css
- For any that don't exist:
- Select Add a new snippet or Add a new asset.
- Enter the correct snippet or asset name.
- Select Create snippet or Create asset.
- Copy and paste the code found in each of these links into their respective files:
Note: Liquid files should go into the snippets folder, and CSS files should go into the assets folder.
- bold-common.liquid
- bold-includes.liquid
- shappify-bdl-load-bundle.liquid
- bold-variant.liquid
- bold-product.liquid
- bold-bundles.css
- Select Save.
- Repeat steps 6.1 – 6.5 for each missing snippet or asset file.
Step 2: Edit bold-includes.liquid
-
Under Snippets, select bold-includes.liquid.
- Copy and paste this code into the bottom of the file:
{{ 'https://bundles.boldapps.net/js/bundles.js' | script_tag }}
{{ 'bold-bundles.css' | asset_url | stylesheet_tag }}
- Select Save.
Step 3: Edit theme.liquid
-
Under Layout, select theme.liquid.
- Copy and paste this code directly under the content_for_header:
{%- include 'bold-product' with product, hide_action: 'header' -%}
{%- include 'bold-common' -%}
{%- include 'bold-common' -%} - Select Save.
Step 4: Edit main-product.liquid
-
Under Sections, select main-product.liquid.
- Copy and paste this code outside of the first product form:
{%- render 'shappify-bdl-load-bundle' -%}
- Select Save.
Step 5: Edit main-cart-items.liquid
-
Under Sections, select main-cart-items.liquid.
- In the else condition of the second statement:
replace:{%- if item.original_line_price != item.final_line_price -%}
with:<span class="price price--end">
{{ item.original_line_price | money }}
</span><div class="money" data-line-index="{{ forloop.index0 }}" data-line-total>
{{ bold_item_line_price | money }}
</div> - Select Save.
Step 6: Edit main-cart-footer.liquid
-
Under Sections, select main-cart-footer.liquid.
- Find the code that looks like:
{{%- cart.total_price | money_with_currency }}
- Copy and paste this code directly before that line:
<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_total" style="display:none !important;"></span>
- Find the <noscript> code snippet:
and replace it with the following:<noscript>
<button type="submit" class="cart__update-button button button--secondary" form="cart">
{{ 'sections.cart.update' | t }}
</button>
</noscript><noscript></noscript>
<div></div> <!-- Override the Shopify 2.0 theme .cart__ctas>:not(noscript:first-child)+ script -->
<button type="submit" class="cart__update-button button button--secondary" form="cart">
{{ 'sections.cart.update' | t }}
</button> - Select Save.
V3 Code Install Instructions (Online Store 2.0 Themes)
This installation allows the bundles to appear on the product page and discount correctly on the product, cart and checkout page.
Step 1: Add Snippet and Asset Files
- Duplicate themes to create a backup copy.
- From the Shopify admin, select Online Store.
- Select Actions.
- Select Edit code.
- Under Snippets and Assets, find these files:
- bold-pr.liquid.liquid
- bold-common.liquid
- bold-includes.liquid
- shappify-bdl-load-bundle.liquid
- bold-bundles.css
- For any that don't exist:
- Select Add a new snippet or Add a new asset.
- Enter the correct snippet or asset name.
- Select Create snippet or Create asset.
- Copy and paste the code found in each of these links into their respective files:
Note: Liquid files should go into the snippets folder, and CSS files should go into the assets folder.
- bold-pr.liquid
- bold-common.liquid
- bold-includes.liquid
- shappify-bdl-load-bundle.liquid
- bold-bundles.css
- Select Save.
- Repeat steps 6.1 – 6.5 for each missing snippet or asset file.
Step 2: Edit bold-includes.liquid
-
Under Snippets, select bold-includes.liquid.
- Copy and paste this code into the bottom of the file:
{{ 'bold-bundles.css' | asset_url | stylesheet_tag }}
{{ 'https://bundles.boldapps.net/js/bundles.js' | script_tag }} - Select Save.
Step 3: Edit theme.liquid
-
Under Layout, select theme.liquid.
- Copy and paste this code directly under the {{ content_for_header }}:
{%- render 'bold-pr' -%}
{%- render 'bold-common' -%}
{%- render 'bold-includes' -%} - Select Save.
Step 4: Edit main-product.liquid
-
Under Sections, select main-product.liquid.
- Copy and paste this code outside the first product form:
{%- render 'shappify-bdl-load-bundle' -%}
- Select Save.
Step 5: Edit main-cart-items.liquid
-
Under Sections, select main-cart-items.liquid.
- In the else condition of the second statement:
replace:{%- if item.original_line_price != item.final_line_price -%}
with:<span class="price price--end">
{{ item.original_line_price | money }}
</span><div class="money" data-line-index="{{ forloop.index0 }}" data-line-total>
{{ bold_item_line_price | money }}
</div> - Select Save.
Step 6: Edit main-cart-footer.liquid
-
Under Sections, select main-cart-footer.liquid.
- Find the code that looks like:
{{%- cart.total_price | money_with_currency }}
- Copy and paste this code directly before that line:
<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_total" style="display:none !important;"></span>
- Find the <noscript> code snippet:
and replace it with the following:<noscript>
<button type="submit" class="cart__update-button button button--secondary" form="cart">
{{ 'sections.cart.update' | t }}
</button>
</noscript><noscript></noscript>
<div></div> <!-- Override the Shopify 2.0 theme .cart__ctas>:not(noscript:first-child)+ script -->
<button type="submit" class="cart__update-button button button--secondary" form="cart">
{{ 'sections.cart.update' | t }}
</button> - Select Save.
Step 7: Edit cart-drawer.liquid
Alert
This step is only for themes with Ajax carts.
-
Under Sections, select cart-drawer.liquid.
- Find the code that looks like:
{{ cart.total_price | money_with_currency }}
and copy and paste this code directly before that line:<span class="Bold-theme-hook-DO-NOT-DELETE bold_cart_total" style="display:none !important;"></span>
- In the else condition of the if statement:
replace:{%- if item.original_line_price != item.final_line_price -%}
with:<span class="price price--end">
{{ item.original_line_price | money }}
</span><div class="money" data-line-index="{{ forloop.index0 }}" data-line-total>
{{ bold_item_line_price | money }}
</div> - Select Save.
Pro-Tip
If you are unsure of whether you are using a Vintage or Online Store 2.0 theme, please visit Shopify’s article Theme architecture versions.
Code Removal
If you would like to remove the liquid code from your theme, the liquid code can be removed by deleting the snippet files, asset files, and the code includes mentioned in the instruction steps above.
You can otherwise request a code removal by contacting our Merchant Success team.
You can remove the app from your by following this guide: Uninstall an App from Your Store.
Pro-Tip
If you are experience issues with performance on the storefront with Bold Bundles after completing the steps above, we recommend requesting a Bundles install. Your theme may require further liquid code changes.