stripe-archive / react-stripe-elements

Moved to stripe/react-stripe-js.
https://github.com/stripe/react-stripe-js
MIT License
3.03k stars 319 forks source link

<IdealBankElement> documentation #510

Closed nejurgis closed 4 years ago

nejurgis commented 4 years ago

I've been trying to set up a custom payment system with Gatsby and react-stripe-elements but theres's so many conflicting guides to do it in the documentation. Ive been following this repo as an example: https://github.com/stripe/react-stripe-js/blob/master/examples/hooks/5-iDEAL.js

However, it's not complete as the IDEAL payment method requires a secondary step where the user gets redirected to their bank page. I've managed to achieve that with stripe.createSource but in the docs i've learned that it's the old way of doing it (?) and now you need to use createPaymentMethod but that also requires a paymentIntent? I'm a tad confused..

Could anyone give a full example of how IDEAL payments are supposed to be implemented in 2020 ?

hofman-stripe commented 4 years ago

Hi @nejurgis, this guide should have all the steps to accept an IDEAL payment, including creating the PaymentIntent and confirming with react examples.

However it is using the newer @stripe/react-stripe-js library and not this library which is now in maintenance mode.

nejurgis commented 4 years ago

hey @hofman-stripe thanks for your answer, any idea how would one recreate this with SSR? (I am using @stripe/react-stripe-js with Gatsby)

hofman-stripe commented 4 years ago

React Stripe.js supports SSR. loadStripe returns a promise that resolves to null on the server, which prevents the React Stripe Elements from rendering.

asolove-stripe commented 4 years ago

Let us know if you still need help with this!