#noah_docs

1 messages Β· Page 1 of 1 (latest)

silk vesselBOT
#

πŸ‘‹ Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

πŸ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1431046638096351255

πŸ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

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.

woeful orbit
#

so i know this view uses <CardField >

but i am confused how they got it to work since whenever i try to display embedded elements its always disabled

#

i am guessing this is embeddedPaymentElementView but i am not sure

forest tangle
#

Hi there,
I will be with you in just a second. Helping another user but i will be with you in just a moment.

#

Alright, sorry for the delay.... busy day today.

#

Let me take a look...

woeful orbit
#

No worries at all - thanks for helping out

forest tangle
#

Are you using our iOS SDK?

woeful orbit
#

React native sdk

forest tangle
#

Got it. I will have to reach out to a colleague. Give me one sec.

woeful orbit
#

🫑

rose bridge
#

πŸ‘‹ I'm the colleague but also know nothing about mobile (sorry) but we're looking into it internally

woeful orbit
#

🫑 will wait - thanks guys

rose bridge
#

And to be clear you have built a real demo of this right?

#

Like

tried with useEmbeddedPaymentElement but as explained its always isLoaded false so the embeddedPaymentElementView is always disabled
what does that mean? Can you share some code?

woeful orbit
#

Yea, also sent it in previous tickets

And yea let me get some code ready to send

rose bridge
#

yeah it's a lot of work to try and go fish in past threads to understand the whole picture unfortunately (though I do know it ends up being work for you to try and summarize too)

woeful orbit
#

Yea for sure I got u, will send it nicely here

rose bridge
woeful orbit
#

Sorry sorry should have been more clear

The screenshots are from an app I am trying to recreate,

They seem to be using the embedded elements

But the docs linked use payment sheet and I want to use embedded element to display the options with other ui around it if that makes sense

Here is the screenshot from my app when I try to do the same

It’s always disabled I assume because isLoaded is always false

#

so i can never click any of the elements

#

but the sheet works perfectly fine

rose bridge
#

Okay but if it worked that's what you want right?

woeful orbit
#

yea exactly, i am just confused why it does not work

rose bridge
#

So let's just ignore the other app entirely and focus on why this isn't working for you.
Can you share your exact code?

woeful orbit
#

sure, give me a sec

#

sorry never know how to do this to give you the best picture, there are so many dependencies etc

i attached relevant (i hope) files and the 2 functions from PaymentService

createEmbeddedIntentConfiguration(currencyCode: string = 'CAD'): IntentConfiguration {
  return {
    mode: {
      currencyCode,
      setupFutureUsage: 'OffSession',
    },
    confirmHandler: this.confirmHandler.bind(this),
  };
}

createEmbeddedElementConfiguration(): EmbeddedPaymentElementConfiguration {
  return {
    merchantDisplayName: 'Barberflow',
    returnURL: 'barberflow://stripe-redirect',
    applePay: {
      merchantCountryCode: 'CA',
    },
    appearance: stripeAppearance,
  };
}
#

stripe.tsx = StripeProvider
use-embedded-payments = a hook with all required functions
index.tsx = the cart/checkout sheet

rose bridge
#

oh boy that's hundreds of lines of code πŸ˜“

woeful orbit
#

😭 yea i am so sorry, is there something specific i can send to help you out

rose bridge
#

Is there any way for you to make the simplest possible demo that literally just loads the element and nothing else from your own app as a completely separate demo?

woeful orbit
#

okay sure, let me do that

rose bridge
#

Thanks. We're trying in parallel too

woeful orbit
#

hi i made a git repo with the bare minimum (i think)

https://github.com/NoahGdev/stripe-embedded-demo

the publishableKey and stripeAccountId are real and valid

i did not add functionality for client secret because its not needed i think, we just wanna see why its not loading properly right?

rose bridge
#

thanks I think we're getting close to your repro too. We were on an older version of the SDK that didn't have your isLoaded

woeful orbit
#

sounds good

silk vesselBOT
rose bridge
#

okay @silk nest is taking over and I think you spoke to them yesterday and already had a support ticket ongoing

silk nest
#

πŸ‘‹ hi there

woeful orbit
#

Sounds good, Hi again Orakaro

apologies for another ticket πŸ₯²

silk nest
#

Please do allow me some times to run the app. Thanks for providing the repo

woeful orbit
silk nest
#

The older SDK doesn't have embeded Elements. So if you want embeded Elements, we will need to stick to this new version.

woeful orbit
#

oh okay

silk nest
#

Hi, could you clarify which Stripe RN SDK version you are using?

woeful orbit
#

Hi

0.55.0

silk nest
woeful orbit
#

😭

#

man, so sorry for all this i wish i knew about expo stripe sdk bundling like that

do i have to wait for expo to update to latest version or how does it work?

no worries if u dont know or dont have time to reply about it if its long

silk nest
#

No worries! Yes generally you wouldn't need to wait for expo update. Maybe you can try to build directly without expo?

woeful orbit
#

that makes sense, will give it a go

otherwise will stick with 0.50.3, seems to work well

thanks so much for taking the time to help

silk nest
#

Hi there, @woeful orbit one minute, if you are still here

woeful orbit
#

Hi, yea still here whats up

silk nest
#

Sorry I think 0.50.3 should have the embeded Elements as well

#

We have me + another colleague trying your repo now. Let us dig a bit deeper

woeful orbit
#

Oh really?

i tried after downgrading to 0.50.3 and it works and lets me interact with it

i will clear cache etc and retry now

for context also my expo sdk is 54.0.10

thanks for looking into it deeper, i will stay here in case i can give any more info or throw up some more code for you

silk nest
#

Ah okie, so downgrading to 0.50.3 does work

#

awesome, was just trying to verify it really works

woeful orbit
#

yessir, thanks so much honestly I think it would have taken me days to think of expo bundling different versions lol

you guys are the goats