react-native-fabric: undefined is not a function (evaluating SMXCrashlytics.recordError(newError))
Trying to integrate react-native-fabric in an Android project I’m working on and this came up. I’m using react-native v0.22.2 and react-native-fabricv0.1.0and followed Fabric’s instruction to get Crashlytics running in the app and my project now shows up on the dashboard of my Fabric account.

Seems to point to Line 52 in Crashlytics.js, which just calls SMXCrashlytics.recordError(newError);
I added a console.log to take a look at SMXCrashlytics in chrome and got this:

All the other functions appear to be there. Is there something I’m missing? Any help would be appreciated.
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 10
- Comments: 29 (13 by maintainers)
Commits related to this issue
- Merge pull request #23 from AppSaloon/master fixes or related to #10 #13 #15 #20 #22 #21 — committed to corymsmith/react-native-fabric by corymsmith 8 years ago
Can we adjust the API so it’s the same for android and iOS. It seems that having
Crashlytics.logExceptionfor Android andCrashlytics.recordErroris confusing for users.Had same issue with
SMXCrashlytics.crashmethod, reason was thatrnpmdidn’t addnew FabricPackage()to list inMainApplication.getPackages()method. You can check everything here https://github.com/corymsmith/react-native-fabric#without-rnpm.Mainly just been busy, will try to get a release out today
I’ll have a look at this today
I’ve had the same issue. But then I realized that I was doing npm install react-native-fabric and rnpm install react-native-fabric.
What I did: npm install react-native-fabric and rnpm link react-native-fabric (note link instead of install) and then rebuild and run the project.
This solved the problem