Discussions

Ask a Question

Cambio de Smart Cart

Cuando tengo un producto que doy gratis en el smart cart quisiera que no ocupara tanto espacio de mi carrito y que la imagen se viera a la izquierda y la info a la derecha (en dos columnas y no en una como aparece ahora) como lo puedo hacer?
ANSWERED

Can't use @rebuy/rebuy-hydrogen with @shopify/hydrogen version 2023.7.1

Greetings, community! Questions regarding Rebuy npm package and hydrogen package version 2023.7.1. Unfortunately, there are no clear instructions for this version of hydrogen. Therefore, I will show what flow I use: after installing the package, I wrap the components in the RebuyContextProvider in the `entry.client.tsx` file. The error that occurs - `../../node_modules/@rebuy/rebuy-hydrogen/RebuyContextProvider.client.jsx:4:9: ERROR: No matching export in "../../node_modules/@shopify/hydrogen/dist/production/index.js" for import "useCart" ../../node_modules/@rebuy/rebuy-hydrogen/RebuyContextProvider.client.jsx:4:18: ERROR: No matching export in "../../node_modules/@shopify/hydrogen/dist/production/index.js" for import "useShop" ../../node_modules/@rebuy/rebuy-hydrogen/RebuyContextProvider.client.jsx:4:27: ERROR: No matching export in "../../node_modules/@shopify/hydrogen/dist/production/index.js" for import "useUrl"` can't import useCart, useUrl, useShop from @shopify/hydrogen - they simply do not exist in the current version of hydrogen. I guess there should be another aproach, but not sure @rebuy/rebuy-hydrogen can be used with hydrogen-2.0 due to old last update (Published 7 months ago). Really appreciate any help. Many thanks in advance!
ANSWERED

Reloading product recommendation on variant change

We're looking for a way to reload our product recommendation from Rebuy whenever our user change a product variant. Since switching variants didn't reload the whole product page, we're stuck with the recommendation from the first variant shown in the page. Is there a way to reload the product recommendation through javascript?

Needs documentation of Methods for Widget Custom Templates

Hi, I'm using the custom template and I notice these methods (variantOptionAvailable and selectVariantOption) aren't included in the documentation and I will need it to modify it further. Example code below. Thank for any kinds of help. ``` <div class="variant-option" v-if="option.name.toLowerCase() == 'color' || option.name.toLowerCase() == 'colour' " > <label>COLOUR</label> <div class="option-swatch color" v-bind:class="{ activeSwatch: product.selected_variant['option' + option.position] == value, unavailable: !variantOptionAvailable(product, 'option' + option.position, value) }" v-for="(value, index) in option.values" v-on:click="selectVariantOption(product, 'option' + option.position, value)" > <div class="option-swatch color-container" :style="{ backgroundImage: 'url(' + getURL(value) + ')' }" ></div> </div> </div> ```

Metafield MetaObjects

Seems that the Metafields option does not return information about metaobjects at all. Is there any timeline on where metaobject information could be made available?
ANSWERED

Product Models and the Media Collection

We are looking to leverage the newer Shopify Media object for video on product pages. Looking at the rebuy widget product model it appears only to show the Image collection. Is there any plan to use Media, or is there an option to enable the Media collection in the product models?

Rebuy app smartcart item quantity change.

I want to change rebuy lineItem quantity from label to dropdown select or input tag, so that on change of item input field by typing lineItem change accordingly increase or decrease. I didn't found any onChange/change method for smart cart. theres only increaseItem decreaseItem

Data Source Create API

Is it possible to create and update Data Source using API? I am hopping to update Data source rules from our ERP system. Thanks

Update cart drawer after adding new item through Javascript

I'm trying to refresh the Smart Cart after adding a new item to the cart using Shopify's AJAX API. However, after the request is completed, the product gets added to the cart, but the Smart Cart doesn't update with the new item. Is there a method I can call through Javascript to update the Smart Cart after a new item is added? Thanks in advance!

Track Post-Purchase page's purchases using TikTok pixel

One of our clients wants to track the purchases that are done through the Post-Purchase page using Tiktok pixel. Is there an event, API, or something that I can use to trigger the TikTok pixel every time a post-purchase is made through the app?