If you're using Headless Hydrogen themes, you need to implement the following changes so that the Fast Bundle App's widgets can load and display on your site.
Here is a code that you must add to your theme, and it should be available on all of your shop's pages:
window.Shopify = {"shop": <myshopify domain>, "currency": {"active": <currency code>, "rate": <rate>}, "locale": <language code>, "routes": {"root": "/"}}
Please be aware that variables must be included in the window, the way that your codes let the script run on every page. To check, you can run "Shopify" in console and see whether you get a response or not.
Also, when loading on product pages, please import the following code as well because our app needs to read the product ID when loading on a product page:
window.pid = <product id>
Next, please implement this script and import it into your new theme's code in the <head> section.
<script src="https://api.fastbundle.co/scripts/script_tag.js" async type="application/javascript"></script>
If you've completed the previous steps, now you must check if the API in domain/cart.js
has been implemented, as shown in the following shopify document.
We hope this article has been helpful! If you have any further questions or need additional assistance, don’t hesitate to reach out to the Fast Bundle support team. You can contact us through the following options:
Live Chat: Get instant help via live chat on our website or through the Fast Bundle admin panel in your Shopify dashboard.
Email: Send your inquiries to Support@fastbundle.co, and our team will respond as quickly as possible.
We’re always here to assist you!