#DrK D. Pupusas

1 messages · Page 1 of 1 (latest)

little swallowBOT
old prism
#

Hi 👋

The Payment Element requires Stripe to be loaded and a valid client secret.

clear void
#

Okay cool. So the form shouldn’t show whatsoever if the promise has resolved

#

Hmm I’m having an issue where stripe and the element returned from the hooks are still returning null for some handful of users. And they shouldn’t be able to hit submit unless they’ve completed the form.

#

But the form hasn’t loaded if the stripe promise hasn’t resolved

old prism
#

Do you have a front-end I could look at? Any code examples?

clear void
#

Ya give me one second.

#

Anything in specific. dont want to show whole files just to be safe.

old prism
#

A test front-end would be more helpful here.

clear void
#

Let me make one and then Ill send it over. Thanks for the help

old prism
#

Okay I'm not seeing anything load on that page.

clear void
#

O you want a form that works and loads completely not just code??? Thats gunna be a bit of a setup.

old prism
#

Okay first thought is try turning off StrictMode

#

Also I'm not seeing anything in App.js or index.js that loads anything from Stripe.

clear void
#

Ya I figured you just wanted to see the code. Not it actually load. A bit of a mission since my code involes 3 million other things going on and I don't have that setup in sandbox.

#

Just to ask, what are you trying to see by having the element actually load. I figured all youd really need to see is the Element component wrapper and where useStripe and useElement are being called?

#

And also how im disabling the button

#

Ya this may be a taller task than what I initially expexted. I appreciate you taking the time to try to help me but its going to be a mission to set this up and I may end up taking more of your time. Ill probably just dig a deeper into it myself and see if I can find anything and have something setup being I ask support. Sort of a fault on my end for asking a question like that without being prepared. Sorry for the trouble man.

#

Ill just message in support once I have something setup that can be looked at and ran. I appreciate your help though.