#minhhn-elements
1 messages · Page 1 of 1 (latest)
To use SetupIntents with the PaymentElement, check out this demo here: https://stripe-tinydemos-payment-element-setup.glitch.me/
hi @karmic apex , thanks for the quick response! I have implemented PaymentElement with SetupIntent successfully, but we wouldn't want to have the Country drop down present on the component. Is there anyway I can exclude that from the PaymentElement?
Sure, you can set billingDetails: 'never' to omit collecting the billing address: https://stripe.com/docs/js/elements_object/create_payment_element#payment_element_create-options-fields-billingDetails
Here it is in action: https://wholesale-sponge-bench.glitch.me/
cool! it works perfectly! Thanks a lot @karmic apex !
btw, is there anyway I can mock the SetupIntent to show a PaymentElement in storybook?
Hmm not easily. You need a client secret to load the PaymentElement, which you can only get from the Stripe API
ah ok. never mind that then 😀