Closed ramki1979 closed 7 years ago
I would just make sure to run react-native link
to make sure the android gradle file is set properly.
I have used react-native link, all other functions related to AWS userpool of the lib are working in android.
I am having the same issue for iOS, only seen it when running authenticateUser
so far.
TypeError: Cannot read property 'computeModPow' of undefined
Never mind - I had my Linked Frameworks and Libraries messed up.
@ramki1979 Please try running the example Android project. If that works on your side, then I'd just say double check your version, wipe node modules etc. Let me know if it works for you.
@jmparsons I wil try it today and reply back.
I am using React-Native-Navigation from Wix, so I have to add the Package list myself in the MainApplication.java And I somehow missed added the
new RNAWSCognitoPackage()
This might be the problem.
As @jmparsons mentioned to relook at react-native link
should have solved my problem. But some how I didn't find the packagelist missing this library.
I am only able to find after comparing Example project with mine and wondering how I missed that.
Thanks @jmparsons @gastonconcilio for quick reply.
I encountered this issue as well.
What I did was drag RNAWSCognito.xcodeproj
to my xcode project libraries and add libRNAWSCognito.a
to Build Phases
. (Basically manually linking it). Hope this information helps someone in the future.
I had this same problem and what I missed that I had to do was run pod install
after react-native link pod 'RNAWSCognito', :path => '../node_modules/amazon-cognito-identity-js'
to Podfile automatically, but I hadn't installed it, and sure enough: Installing JKBigInteger2 (0.0.5) Installing RNAWSCognito (1.29.0)
showed up in my terminal and now I've got user authentication flow on iOS and Android. Yay!
I am using
authenticateUser
on iOS and Android.iOS is working fine. I am running into
TypeError: undefined is not an object (evaluating 'RNAWSCognito.computeModPow')
on android.Anything I am missing here.