-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathreactotron.js
31 lines (28 loc) · 910 Bytes
/
reactotron.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import { NativeModules } from 'react-native';
import Reactotron, {
networking,
openInEditor,
trackGlobalErrors
} from 'reactotron-react-native';
import { reactotronRedux } from 'reactotron-redux';
const scriptURL = NativeModules.SourceCode.scriptURL;
const scriptHostname = scriptURL.split('://')[1].split(':')[0];
const reactotron = Reactotron.configure({
name: 'SG Bus',
host: scriptHostname
})
.useReactNative({
asyncStorage: false, // there are more options to the async storage.
networking: {
// optionally, you can turn it off with false.
ignoreUrls: /symbolicate/
},
editor: false, // there are more options to editor
errors: { veto: stackFrame => false }, // or turn it off with false
overlay: false // just turning off overlay
})
.use(openInEditor())
.use(reactotronRedux())
.use(trackGlobalErrors())
.connect();
export default reactotron;