#nicolejaneway

1 messages · Page 1 of 1 (latest)

coarse hareBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

calm parcel
#

Which step are you at now?

wanton reef
#

Uhm, I'm trying to adapt it to what I have running

#

I tried

      if (submitError) {
        console.log(error);
      }
      const { error, paymentMethod } = await stripe.createPaymentMethod({
        elements,
      });

And now I'm seeing the error:

your elements instance must be created with paymentMethodCreation: 'manual'.

calm parcel
#

How did you create the elements ?

wanton reef
#
  const stripe = useStripe();
  const elements = useElements();
#

Oh, okay, I figured it out.

#
        <Elements
          stripe={stripePromise}
          options={{
            clientSecret,
            paymentMethodCreation: "manual",
          }}
        >