#J Rietz-applePay-supported
1 messages ยท Page 1 of 1 (latest)
Thank you ๐
Apologies for the delay, I do believe that function checks if all pre-reqs are met for the user to use Apple Pay, but am working on double checking.
I think it is working internally within for example the useApplePay() function but not really sure if it can be used as a boolean for other modules. I'd need to trigger this check earlier in the flow in my app to decided wether to display the Apple Pay button or not.
I know when our web payment button checks to see if it should display the Apple Pay option, it checks not only the browser/machine but also that there is actually a card set up in the Apple Pay wallet. My hunch is that this function is doing something similar.
Yes but I guess that check has to be done through some functions? The check can't be taken out of context so to speak
This is meant to be the check you use and should return true or false according to whether Apple Pay is available for payment.
You may want to try isApplePaySupport from the useApplePay hook like you can see in our example screen:
https://github.com/stripe/stripe-react-native/blob/master/example/src/screens/ApplePayScreen.tsx#L38-L61
so like this: