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

Add support for handleCardAction

Open bombek92 opened this issue 5 years ago • 14 comments

Summary & motivation

Added support for https://stripe.com/docs/stripe-js/reference#stripe-handle-card-action

API review

Added new method, not breaking existing code.

Copy this template or link to an API review issue.

Testing & documentation

How did you test this change? Simple unit tests calling this method.

have you updated the documentation? YES

bombek92 avatar Aug 05 '19 14:08 bombek92

Is there any workaround to use this feature before this patch is merged?

tremby avatar Aug 21 '19 16:08 tremby

Is there any workaround to use this feature before this patch is merged?

  private handleCardAction = async (clientSecret: string, paymentIntentId: string) => {
    const result = await (this.props.stripe as any).handleCardAction(clientSecret);
    (...)
  }

bombek92 avatar Aug 22 '19 11:08 bombek92

Approximately when can we expect this feature to be available? The SCA rule will come into effect in Europe on September 14. So, like in 2 weeks we won't be able to use Stripe on our project for payments...

tamas-norbert-miklos avatar Aug 29 '19 07:08 tamas-norbert-miklos

I'm happy to be the one giving the good news to you. The new regulation has been postponed 18 months source (edit: as @bombek92 pointed this is for UK only)

poteirard avatar Aug 29 '19 07:08 poteirard

I'm happy to be the one giving the good news to you. The new regulation has been postponed 18 months source

FYI This is UK only.

bombek92 avatar Aug 29 '19 07:08 bombek92

I'm happy to be the one giving the good news to you. The new regulation has been postponed 18 months source

FYI This is UK only.

Our projects it's for Italy. So i guess the original deadline still applies.

tamas-norbert-miklos avatar Aug 29 '19 08:08 tamas-norbert-miklos

I'm happy to be the one giving the good news to you. The new regulation has been postponed 18 months source

FYI This is UK only.

Our projects it's for Italy. So i guess the original deadline still applies.

Deadline in Italy seems to have been postponed (no new date set): https://www.bancaditalia.it/media/comunicati/documenti/2019-02/CS_01082019_a_f.pdf (italian)

giupea avatar Sep 06 '19 09:09 giupea

@bombek92 it seems that the travis build is failing. May you please take a look why? With a proper build, this feature will get better change to be merged quickly (I hope it'll, it should help a lot). Thanks.

yamsellem avatar Sep 06 '19 09:09 yamsellem

@bombek92 meanwhile your code is merged, I don't understand your answer on a temporary workaround. Where are you suggesting to add the code you suggest to @tremby?

Because react-stripe-elements is a typescript package, it does not seems possible to use your fork as a npm dependency (adding "react-stripe-elements": "bombek92/react-stripe-elements" to a package.json dependencies does not work).

Thanks again.

yamsellem avatar Sep 06 '19 09:09 yamsellem

@bombek92 meanwhile your code is merged, I don't understand your answer on a temporary workaround. Where are you suggesting to add the code you suggest to @tremby?

Because react-stripe-elements is a typescript package, it does not seems possible to use your fork as a npm dependency (adding "react-stripe-elements": "bombek92/react-stripe-elements" to a package.json dependencies does not work).

Thanks again.

just use: const result = await (this.props.stripe as any).handleCardAction(clientSecret);

bombek92 avatar Sep 06 '19 13:09 bombek92

@bombek92 it seems that the travis build is failing. May you please take a look why? With a proper build, this feature will get better change to be merged quickly (I hope it'll, it should help a lot). Thanks.

That's why this is draft pr, but I'll try to fix it this weekend.

bombek92 avatar Sep 06 '19 13:09 bombek92

@bombek92 Thanks for your quick answers.

In my client side code, I use react, but in a javascript file (no typescript) and with promise (no await), is your workaround still possible with this, and what would be the code?

Thanks again.

yamsellem avatar Sep 06 '19 13:09 yamsellem

@bombek92 have you found some time to take a look? You would be a life saver if you do. Thanks (14 of September makes me worry to death).

yamsellem avatar Sep 10 '19 07:09 yamsellem

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Maciej Dąbek seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Aug 06 '20 12:08 CLAassistant