I have used react-native-braintree-dropin-ui library in my react-native app. Here is the code that I have used to call react-native-braintree-dropin-ui popup:
BraintreeDropIn.show({
clientToken: brainTreeToken,
countryCode: "US", //apple pay setting
currencyCode: "USD", //apple pay setting
orderTotal: cartAmount.toString(),
googlePay: false,
applePay: false,
vaultManager: true,
cardDisabled: false,
darkTheme: true,
})
.then((result) => {
// here is an api to handle payment on server
})
.catch((error) => {
if (error.code === "USER_CANCELLATION") {
// code to handle user cancellation
} else {
// code to handle error
}
});
It successfully popup the braintree-dropin-ui. But the problem is that in android it only gives option to pay with paypal. It does not displaying "Credit or Debit Cart" option in pop up. However same code displaying both options, Paypal and Credit or Debit Cart in iOS.
Can anyone please help me what's the problem here ?
remove cardDisabled key from options and rerun the code it will show. Because of the commented code in screen shot it is not coming.