#Suruchi Kumari

1 messages · Page 1 of 1 (latest)

ivory spokeBOT
cloud crag
#

Which guides are you following?

simple moth
#

Docs

cloud crag
#

Yup, which ones?

simple moth
#

For react

#

I am following this code

cloud crag
#

What's not working about it?

simple moth
#

I am getting err in stripe button component, I tried to fix it by installing stripe and importing it in my file but still it's showing err in that component

ivory spokeBOT
cloud crag
#

What's the error?

simple moth
#

Code is not recognising this stripe button component

cloud crag
#

That's the error message?

simple moth
simple moth
#

Not the proper message but yeah that message means the same thing

cloud crag
#

Can you show me a screenshot of the error?

simple moth
#

Yeah sure

#

@cloud crag

simple moth
hidden kite
#

Hello! I'm taking over and catching up...

simple moth
#

ok

#

One thing I want to mention here that i am writing my code in typescript in react app

hidden kite
#

I was just about to say, I don't think this approach is compatible with TypeScript unless you set up something special to allow for the custom web component.

simple moth
#

Yeah, so what should I do so that it can be use in my code?

hidden kite
#

I'm not really well versed in TypeScript, but I think you would need to declare the custom element. Maybe something like this?

declare global {
  namespace JSX {
    interface IntrinsicElements {
      stripe-buy-button: React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>;
    }
  }
}
simple moth
#

btw is there any docs available ?

hidden kite
#

Docs available for what?

simple moth
#

I mean docs in typescript

#

About payment integration with stripe

hidden kite
#

Not that I'm aware of, not for this integration.

simple moth
#

Ok, thanks for the help