-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor loadStripe
for Express Checkouts
#9582
Conversation
Test the buildOption 1. Jetpack Beta
Option 2. Jurassic Ninja - available for logged-in A12s🚀 Launch a JN site with this branch 🚀 ℹ️ Install this Tampermonkey script to get more options. Build info:
Note: the build is updated when a new commit is pushed to this PR. |
Size Change: +65 B (0%) Total Size: 1.34 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM and tests well.
✅ I was able to checkout with Google Pay and Apple Pay on a JT domain.
Closes #9685
This refactor originated from a comment (pcrvl0-1sv-p2#comment-743) on a P2 I published. It doesn’t introduce any new functionality. The changes are solely intended to prevent reintroducing the same bug (pcrvl0-1sv-p2) that #9523 fixed it.
Changes proposed in this Pull Request
Since loadStripe was introduced for Express Checkouts, the
forceAccountRequest
parameter is unnecessary, as it should always use the merchant’s connected account with Stripe elements.Therefore, the
forceAccountRequest
parameter is being removed, and the function renamed to clearly indicate it’s for Express Checkouts.All instances of
loadStripe
has been updated to use the newloadStripeForExpressCheckout
Testing instructions
Tip
To thoroughly test these changes, I created a plugin .zip file using
npm run build:release
and applied it to a fresh Jurassic Ninja site. This ensures the domain hadn’t been previously registered.Note
You need to use Ngrok or Jurassic Tube to test Apple Pay.
npm run changelog
to add a changelog file, choosepatch
to leave it empty if the change is not significant. You can add multiple changelog files in one PR by running this command a few times.Post merge