Skip to content

Instantly share code, notes, and snippets.

@mootrichard
Created January 3, 2018 18:40
Show Gist options
  • Save mootrichard/7ac92d29f3fd35ad1246b564ce037821 to your computer and use it in GitHub Desktop.
Save mootrichard/7ac92d29f3fd35ad1246b564ce037821 to your computer and use it in GitHub Desktop.
$.getScript("https://js.squareup.com/v2/paymentform").done(function () {
paymentForm = new SqPaymentForm({
// Setup your SqPaymentForm object, see https://docs.connect.squareup.com/payments/sqpaymentform/sqpaymentform-setup
// for more details
});
// We're manually building the form here, since the page is already loaded and won't trigger the event SqPaymentForm
// is expecting
paymentForm.build();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment