stripe-samples / accept-a-payment

Learn how to accept a payment from customers around the world with a variety of payment methods.
MIT License
652 stars 498 forks source link

Add polling or delay to return pages #3

Closed cjavilla-stripe closed 3 years ago

cjavilla-stripe commented 3 years ago

Some of the redirect payment methods like grabpay will redirect before the payment is done processing. Let's add a poll with setInterval to refetch the payment intent and display a simple log of statuses until success.

cjavilla-stripe commented 3 years ago

Should we just have one RedirectReturn component for React which handles all cases where we're returning back to the app? I think the query string will be the same for all payment methods, but wanted to make sure we want to consolidate or if we should keep them separate.