#James786 - React native
1 messages · Page 1 of 1 (latest)
i want to integrate with JS
the code which you provide that is in Typescript
i need in JS using CLI not expo
This guide covers how to use react native to accept payment, and it doesn't use typescript
https://stripe.com/docs/payments/accept-a-payment?platform=react-native
but it is with expo
import { StripeProvider } from '@stripe/stripe-react-native';
function App() {
return (
<StripeProvider
publishableKey="pk_test_51L415IJiREfmU884Sg...N3IxouEsu002jck3cpk""pk_test_51L415IJiREfmU884Sg6ttsAxCe5hc1OosBTqAu2VmS3QgnYOaQFXiNgoIAtvZJeh1vNnqYDXrJyhLR8N3IxouEsu002jck3cpk"
urlScheme="your-url-scheme" // required for 3D Secure and bank redirects
merchantIdentifier="merchant.com.{{YOUR_APP_NAME}}" // required for Apple Pay
>
// Your app code here
</StripeProvider>
);
}
may i use service provider on my CLI file not on App.js file
??
may i use service provider on my CLI file not on App.js file
I'm sorry I don't understand your question. Does the code you shared work? If not what's the error message?
your documentation is saying that.. use service provider on App.js file and wrap all code under this... i am saying that may i use this service provider on direct payment.JS file
So you want to use <StripeProvider> in the payment.js file instead of the app.js file?
yes
I'm not very familiar with React Native, but yes I think this should work.
what is this? urlScheme="your-url-scheme" // required for 3D Secure and bank redirects
from where i get url
Hi there 👋
You can read up about that here
https://reactnative.dev/docs/linking
so which lick here we use?
did you read the doc I sent you?
for this to work, you want to look into deeplinks
Looking for any guides I can send your way
This has some easy to follow steps
https://medium.com/react-native-training/deep-linking-your-react-native-app-d87c39a1ad5e
okay
The customer has not entered their payment method.
some time i got this on dashboad and payment is not successed
I don't think I follow
means?