Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

175
Vistas
React Native: Google Pay/Apple pay using CardField instead of PaymentSheet in Stripe SDK

currently I can't seem to find how to use Google Pay or Apple Pay with CardField component, is it currently possible?

I'm using this Stripe's official reaft-native sdk:

https://github.com/stripe/stripe-react-native

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

you can use initPaymentSheet. This is from what I can see and know the only solution that we have right now (used by me) for Apple or Google Pay... I don't know why the docs (https://github.com/stripe/stripe-react-native) do not talk on their front page about this option, but for me worked just fine. Also, make sure you check the stipe official docs also for more info because they also help with examples and explain the logic for why/how/what to do certain things (stripe docs).

A small example that can help you and others is below:

import {
    useStripe,
} from '@stripe/stripe-react-native';

const {initPaymentSheet, presentPaymentSheet} = useStripe();

IMPORTANT:

In order to show ('work') the bottom sheet (initPaymentSheet) you need either paymentIntentClientSecret OR setupIntentClientSecret. Make sure that you have one of these 2 if not you will get an error :).

await initPaymentSheet({
                applePay: true,
                googlePay: true,
                customerId: customerId,
                merchantCountryCode: merchantCountryCode,
                merchantDisplayName: merchantDisplayName,
                paymentIntentClientSecret: paymentIntentClientSecret,
                setupIntentClientSecret: setupIntentClientSecret,
                customerEphemeralKeySecret:ephemeralKeySecret,
                style: 'alwaysLight',
                primaryButtonColor: 'red',
                allowsDelayedPaymentMethods: true,
                testEnv: 'development',
                customFlow: false,
                defaultBillingDetails: {
                    address: {
                        city: city,
                        country: country,
                        line1: line1,
                        line2: line2,
                        postalCode: postalCode,
                        state: state,
                    },
                    name: name,
                    email: email,
                    phone: phone,
                },
                returnURL: returnURL,
            });
about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda