[Update on March 20, 2019: If you have this issue, check out my post here!]
I'm making a mobile app using Expo and React Native. I would like to integrate React Native Debugger to my project for react and redux debugging. But am having trouble.
Specifically connecting to react devtools have failed. I think this is because I am using Expo client (real device connected via wifi).
According to the docs, I should follow this path.
Since my Expo version is 25.0.0, the RN version is 0.52. Therefore, I must edit the setupDevtools.js.
The problem is, this doc is confusing to me. And I'm not sure whether I'm doing the right thing. So far, as below, I have changed the host to my IP address. But this didn't work. I guess I'm doing something wrong. Could anyone help? Thanks in advance.
const host = PlatformConstants && PlatformConstants.ServerHost ?
PlatformConstants.ServerHost.split(':')[0] :
'localhost';
reactDevTools.connectToDevTools({
isAppActive,
host: "116.0.157.7",
// Read the optional global variable for backward compatibility.
// It was added in https://github.com/facebook/react-native/commit/bf2b435322e89d0aeee8792b1c6e04656c2719a0.
port: window.__REACT_DEVTOOLS_PORT__,
resolveRNStyle: require('../../StyleSheet/flattenStyle'),
});