Skip to content

Conversation

@davidmerfield
Copy link
Owner

Summary

  • calculate and expose Stripe price details for the signup page
  • add a payment request button container alongside the email and card inputs
  • initialize Stripe Payment Request to support Apple Pay/Google Pay and submit tokens via existing flow

Testing

  • not run (not requested)

Codex Task

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines 251 to 255
stripe.createToken(ev.paymentMethod).then(function (result) {
if (result.error) {
renderError(result.error.message);
ev.complete('fail');
} else {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Payment Request button never produces a token

When Apple Pay/Google Pay is available, the new Payment Request handler listens for the paymentmethod event and passes ev.paymentMethod to stripe.createToken. Stripe.js only accepts an Element or token type there, so the promise comes back with an error and stripeToken is never populated, while the server-side signup POST still rejects requests without a stripeToken. The Payment Request button will therefore always fail instead of submitting a subscription; it needs to use the token event or a PaymentIntent flow rather than createToken(ev.paymentMethod).

Useful? React with 👍 / 👎.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants