ReactNative: How to disable Bugsnag in DEV
Sometimes this is hard to disable Bugsnag inside DEV mode, we can simple disable it inside JS thread.
Bugsnag.start({
onError: () => {
if (__DEV__) {
return false;
} else {
return true;
}
},
plugins: [new BugsnagPluginReactNavigation()],
});
Remember that Native crashes will be reported anyway in this solution.
Tweet