iWishlist Integration Guide

📖 iWishlist supports you to add favorite products as well as email or share their wishlist with friends. Here is our guide for integration between iWishlist and Boost AI Search & Discovery.


About iWish: Wishlist

1
App Information

2
iWish: Wishlist Integration Function

  • Allow customers to filter products and add products to their Wishlist.

How to integrate iWish: Wishlist with Boost AI Search & Discovery

This feature only works with Boost AI Search & Discovery V2 and above. To find out which version of our app your store's current theme is installed with, please follow this article.

1

From your Shopify admin, go to Online Store > Themes.

2

Find the theme you'd like to integrate the app and click Actions (⋯) > Edit code.


Select one of the Versions below for the app version that your theme is installed with (if you have not known it, yet, please follow this article to find out): V2 or V3. Then follow its corresponding Step 3


V2

3 (V2)
In Asset folder, search for this file boost-pfs-filter.js. Then locate this line of code:

productGridItemHtml

4 (V2)
Copy and paste this code snippet to where you'd like to add your wishlist:

'{{itemWishlist}}' + // For bc-sf-filter.js or boost-pfs-filter.js

For example, under the product thumbnail:

If the variable productGridItemHtml does not exist in boost-pfs-filter.js, please find it in the file boost-pfs-filter-html.liquid and paste this code snippet instead:

[[itemWishlist]] // for bc-sf-filter-html.liquid or boost-pfs-filter-html.liquid

5 (V2)
In boost-pfs-filter.js file, locate this line of code:

ProductGridItem.prototype.compileTemplate

6 (V2)
Within the function ProductGridItem.prototype.compileTemplate, scroll down to locate this comment line:

// Add main attribute

7 (V2)
Copy and paste this code snippet above the comment line:

// Add wishlistvar

itemWishListHtml = '<a class="iWishAddColl iwishcheck" data-variant="' + firstVariant.id + '" data-product="{{itemId}}" data-ptitle="{{itemTitle}}">Add to Wishlist</a>';itemHtml = itemHtml.replace(/{{itemWishlist}}/g, itemWishListHtml);

Demo for Wishlist @ $2 integration with Boost 3

8 (V2)
In the same file, locate this line of code:

ProductGridItem.prototype.compileTemplate

9 (V2)
Within the function ProductGridItem.prototype.compileTemplate, add this code snippet:

jQ(".iWishAddColl.iwishcheck").on('click', function (e) {

e.preventDefault();

var iWishvId = jQ(this).attr("data-variant");

iwish_addCollection(jQ(this), iWishvId);

return false;});iwishCheckColl();

10 (V2)
Click Save and you're set!

V3

3 (V3)
In Layout folder, locate a file named theme.liquid.
4 (V3)
Add this code snippet before the closing tags at the bottom of the theme.liquid file:

{% include 'iwish_v2' with 'iwishCollection' %}

5 (V3)
In Asset folder, create a new file named boost-sd-custom.js.
6 (V3)
Add the code snippet below to the boost-sd-custom.js file:

if (window.boostSDAppConfig) {

window.boostSDAppConfig.integration = Object.assign({

wishlists: 'i-wishlist'

}, window.boostSDAppConfig.integration || {});

}

7 (V3)
Click Save and you're all set!
8 (V3)
Go back to Shopify Admin > Sales channels > Online Store > Themes > Find the theme you are working on > Customize.
9 (V3)
In the Shopify Theme editor > From the left sidebar, select  App embeds > Toggle ON the 3rd app you'd like to integrate. 

If you encounter any issues during the integration process, please don't hesitate to contact our support team for further assistance at support@boostcommerce.net.