stripe / stripe-js

Loading wrapper for Stripe.js
https://stripe.com/docs/js
MIT License
633 stars 157 forks source link

[BUG]: automatic_async does not exist in captureMethod of StripeElementsUpdateOptions #677

Open hir0o opened 2 weeks ago

hir0o commented 2 weeks ago

What happened?

captureMethod can be 'manual', 'automatic', or 'automatic_async', but only 'manual' and 'automatic' exist.

https://github.com/stripe/stripe-js/blob/master/types/stripe-js/elements-group.d.ts#L722

Environment

No response

Reproduction

No response

brendanm-stripe commented 5 days ago

Hey there, you're quite right the type is missing an option and I've reported this to the Elements team to extend the type.

In the meantime, the actual value is supported and works as expected, so you can use that and temporarily use ts-ignore or ts-expect-error in the interim.