2

I'm trying to setup my environment to develop with react-native and react-devtools. Per default the react-devtool uses port 8097 to connect with the app on the emulator. Unfortunatley, this port is blocked at my workplace. Where/How can i change this port?

I found out that there's an option to configure the devtools with:

const { connectToDevTools } = require("react-devtools-core");
connectToDevTools( { port: "customport" } );

I just don't know where to place this config.

I managed to change the app so that it tries to connect to a different port, but i can't seem to change wart port the devtool client (?) uses (see image)

Any help is appreciated

Marcel B.
  • 21
  • 1
  • Does this answer your question? [react-devtools: By default DevTools listen to port 8097 on localhost. How to customise?](https://stackoverflow.com/questions/43074677/react-devtools-by-default-devtools-listen-to-port-8097-on-localhost-how-to-cus) – vovchisko Jan 08 '21 at 11:41
  • This question seems answered. https://stackoverflow.com/questions/43074677/react-devtools-by-default-devtools-listen-to-port-8097-on-localhost-how-to-cus – vovchisko Jan 08 '21 at 11:42
  • 1
    As i wrote above: i found that thread, but i don't know where exactly i should add that, ie.e which file. I added it my my App.tsx, but the client in the screenshot linked above still shows that port 8097 is uesd – Marcel B. Jan 08 '21 at 11:49
  • Anyone here able to share their example? I'm running out of ideas on how to put the instance. – Kaydarin Sep 27 '21 at 13:51

0 Answers0