Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem getting React Native project to recognize RNStripeTerminal #33

Open
khuang-citylift opened this issue Jan 7, 2020 · 5 comments

Comments

@khuang-citylift
Copy link

khuang-citylift commented Jan 7, 2020

Hi, the issue that I am having is my project does not recognize the RNStripeTerminal object. The failure is on the line of import:

import StripeTerminal from 'react-native-stripe-terminal';

The exact error I am getting is:
null is not an object (evaluating 'RNStripeTerminal.DeviceTypeChipper2X')

I have successfully linked 'react-native-stripe-terminal' to my react native project because I see the following in my Podfile:

pod 'StripeTerminal', '1.0.3'
pod 'RNStripeTerminal', :path => '../node_modules/react-native-stripe-terminal'

The path is correct and I see the react-native-stripe-terminal folder in my node_modules.
I have also followed the iOS SDK set up instructions here: https://stripe.com/docs/terminal/sdk/ios#install

I am not sure what I could be missing and I am hoping to get some advice on how I can troubleshoot this further. Thank you!

@rfischer20
Copy link

@khuang-citylift Did you have any luck with this? We have been at a standstill with the same issue trying to get this moving forward.

@khuang-citylift
Copy link
Author

@rfischer20 No, I did not get react-native-stripe-terminal working but I found a workaround and that was to use to react-native-webview. We ended up just rendering the webpage inside of the react native application.
https://github.com/react-native-community/react-native-webview

@rfischer20
Copy link

@khuang-citylift appreciate the update! Did not know you could access the devices through the webview - we'll check it out

@vivekvardhanadepu
Copy link
Contributor

@khuang-citylift It has something to do with the ios target iirc. Change it to some higher version and see if it works

@RichSDavies
Copy link

@rfischer20 No, I did not get react-native-stripe-terminal working but I found a workaround and that was to use to react-native-webview. We ended up just rendering the webpage inside of the react native application. https://github.com/react-native-community/react-native-webview

We have also decided to go down this route, having issues with an android device where it cannot communicate with reader, terminal is onm same network just wondering if you had seen this issue. Works fine on emulator and when i run the js in a browser

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants