Skip to content

Commit

Permalink
Test with Country
Browse files Browse the repository at this point in the history
  • Loading branch information
JDWaghela authored May 23, 2024
1 parent 222acce commit 69dd97b
Showing 1 changed file with 11 additions and 16 deletions.
27 changes: 11 additions & 16 deletions checkout.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,7 @@ function initStripe({ stripe: stripeObj = {} }) {
elements = stripe.elements(options);
let paymentElementOptions = {
fields: {
billingDetails: {
address: {
country: "never",
postalCode: "never",
},
},
billingDetails: "auto",
},
savePaymentMethod: {
maxVisiblePaymentMethods: 3,
Expand Down Expand Up @@ -165,16 +160,16 @@ async function getConfirmationToken() {
try {
const { error, confirmationToken } = await stripe.createConfirmationToken({
elements,
params: {
payment_method_data: {
billing_details: {
address: {
country: null,
postal_code: null,
},
},
},
},
// params: {
// payment_method_data: {
// billing_details: {
// address: {
// country: null,
// postal_code: null,
// },
// },
// },
// },
});

if (error) {
Expand Down

0 comments on commit 69dd97b

Please sign in to comment.