react-stripe-elements icon indicating copy to clipboard operation
react-stripe-elements copied to clipboard

PaymentRequestButtonElement Integration Error with saved browser card

Open varunrau opened this issue 5 years ago • 1 comments

Feature request or idea? Consider opening an API review!

Summary

Hello, I'm integrating the PaymentRequestButtonElement and am getting an Integration error when trying to render a payment request button when the user has a saved card (not google or apple pay). I do have a canMakePayment check and will only attempt to render if I receive a truthy value. In my case, that value is { applePay: false, googlePay: false }.

The error I receive is IntegrationError: For the paymentRequestButton Element, you must first check availability using paymentRequest.canMakePayment() before mounting the Element.

I tried creating a minimal repro with JSFiddle, but I'm getting a different IntegrationError there 😅. JSFiddle: https://jsfiddle.net/mqbtL3cx/53/

Note that my code works correctly when the user has Apple Pay configured in the browser in Safari.

This only happens in Chrome. On Safari, the Apple Pay button renders correctly!

varunrau avatar Mar 15 '21 21:03 varunrau

Hi @varunrau -- I'm working on closing issues on this repository, since the project has migrated to React Stripe.js as of early 2020. We've had a harder time keeping track of issues because of this older repository hanging around still. If you are still experiencing this issue, please open it there.

sashko-stripe avatar Mar 26 '21 18:03 sashko-stripe