Skip to content

Conversation

@lukeholder
Copy link
Member

Description

Add a folder containing example templates

  • Buy button JS Example template

@lukeholder
Copy link
Member Author

lukeholder commented Nov 10, 2022

@AugustMiller what do you think, a whole page example templates or just put this example into the README?

@AugustMiller
Copy link
Contributor

I like the idea of stubbing the example-templates folder as a nod to Commerce. I struggled with condensing an example that fit in the Readme, because there is so much boilerplate stuff with both the JS Buy SDK and Buy Button JS.

This particular example, though, I think we should avoid, because it doesn't make use of synchronized data… in its current state, this would be almost entirely possible to build without Craft, the plugin, etc. (so long as you had access to the product IDs).

Is there any way to bootstrap only the cart component, then render out our own custom product tiles that leverage a combination of Shopify + Craft data? I had to turn my attention elsewhere before I was able to find a way of interacting with the cart, like you can with the JS Buy SDK… but maybe because this is based on it, all that still applies?

Sorry if this is a nothingburger of a reply—hope it tracks?


In the interim, I added a couple sections (I think you already saw + merged) proffering the two Shopify libraries… but I still feel pretty strongly that the forced brevity works against us, and a folder of drop-in demo templates would be much easier for people to work with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants