#MikeyBeLike-elements

1 messages · Page 1 of 1 (latest)

torn flame
proper heath
#

This is my code:

const stripe = await loadStripe(stripeKey);
        this.stripeElements = stripe.elements({
            clientSecret: this.clientSecret,
        });

        const paymentElement = this.stripeElements.create("payment");
        paymentElement.mount("#payment-element");
#

I've checked the payment intent under "events" and can see the key client_secret with the same value that is passed in

torn flame
#

Hm... Just to confirm - you've logged this.clientSecret and confirmed it's of the form pi_xxx_secret_yyy right?

proper heath
#

yep

#

it's under a connect account if that helps

#

when using loadStripe am I meant to pass in the accounnt id too?

torn flame
#

Yes - if you created the Payment Intent with Stripe-Account you should also pass that in client-side

proper heath
#

nvm, I see it's in the types:

torn flame
#

👍 Yeah try that out and see if you still get the same error

proper heath
#

all good now, thnx