What is the difference between these two buy button libraries?

What is the difference between these two buy button libraries?

dogowner
Shopify Partner
59 5 8

I started this project at least a year or two ago and am having problems with checkouts now.  Can anyone explain to me the different between these two libraries:

 

https://sdks.shopifycdn.com/buy-button/latest/buy-button-storefront.min.js

 

https://sdks.shopifycdn.com/buy-button/latest/buybutton.min.js

 

Thanks.

Replies 4 (4)

dogowner
Shopify Partner
59 5 8

Here is more info but not very helpful -- https://github.com/Shopify/buy-button-js/issues/388

dogowner
Shopify Partner
59 5 8

The versions do not seem to make much sense and there doesn't seem to be much documentation about it. 

dogowner
Shopify Partner
59 5 8

Adjusted to use buybutton.js by dropping Promise usage and switched to assignment. Issues still persist:

 

https://github.com/Shopify/js-buy-sdk/issues/917

 

https://github.com/Shopify/buy-button-js/issues/827

 

 

 

- ShopifyBuy.UI.onReady(shopifyClient).then(function (ui) {
- let options = myOptions;
- ui.createComponent('cart', {
- moneyFormat: '%24%7B%7Bamount%7D%7D',
- options: options,
- });https://github.com/Shopify/buy-button-js/issues/827
+ var ui = ShopifyBuy.UI.init(shopifyClient);
+ var options = myOptions();
+ ui.createComponent('cart', {
+ moneyFormat: '%24%7B%7Bamount%7D%7D',
+ options: options

 

dogowner
Shopify Partner
59 5 8

Original usage I think came from buy button sales channel in store admin but I can't seem to find any information about it or how it has grown/changed into the also poorly supported buybutton.js.