Stripe Payment integration with React

Viewed 15

I'm trying to integrate Stripe payment method into React application. I have followed Stripe offical documentation and installed all required libraries. I'm using PaymentElement for collecting the card details such as card number, expiry date, CVC number, postcode. How could I check if all the card details are provided on a button click; if not, alert them to the text fields so that they add the payment details please ?

Thanks for your help in advance.

Regards Mahesh

1 Answers

The PaymentElement does have validations built-in for these checks. Are you not seeing any error messages or any pointers to missing fields? It works for me.

Screenshot

Related