I don't know why "Debug JS Remotely" is not showing on iOS simulator
Versions:
・RN:v0.62.0
・OS::macOS 10.15.3
・Xcode:11.3.1
Any solution??
With new react native versions, They have disabled hot reloading and live reloading with fast refresh and for your case Debug JS remotely has been changed to Start Debug. That will open up a browser in your system.
Hope it helps. feel free for doubts.
You're already debugging as you've turned on debug JS remotely(Start Debug newer version) ,open chrome and open inspect and tap on console ,you'll get the logs there, else to stop Just press on stop debugging to find debug JS remotely
Related
With old Android versions, app is so slow working when debug js remotely is active. Is there a way to see the logs which we have on Chrome ?
If Chrome is the issue, you can use React Native Tools Extension on Visual Studio. That way you can simply use VS code itself for reading logs.
EDIT: If putting Remote Debugger ON the issue, go ahead and use react-native log-android or react-native log-ios . Click here for more information on accessing console logs
You can use the server terminal for that, all consoles are going to be availabe there for you and you wont need to enable "debug remotly"
In order to use React Native Debugger, I don't see the option 'Debug JS Remotely' when I open the Developer Menu both on my android simulator and my physical device, using expo. Tried both scenarios and no option for Debug JS Remotely...
(I originally wanted to use my external device with React Native Debugger and I can't find the setupDevtools.js file at node_modules/react-native/Libraries/Core/Devtools/setupDevtools.js in order to update this file for use. I don't know if these two might be related, but also wanted to share)
Am I missing something? Thank you...
I guess the option Debug JS Remotely has been replaced by the option Debug with the latest version of react-native.
And If you want to use your external device with a debugger just shake the device and select the debug option from the developer menu.
But as #JoeBe suggested you should also look for an already open debugger and then try it.
You can also open the developer menu just by pressing d on node.js screen if you are using the latest version of react-native.
I had the same issue. But as it turns out, after terminating all other debuggers it was working with that Debug option as well.
I am trying to to debug the react native app, If I don't try to debug JS remotely then everything is fine, but when I try to debug JS remotely I do get this error.
I had this error too. The reason for me was the opened debugger tab in chrome from previous session. So when I closed it everything works fine now :)
try to change your URL of Chrome from http://localhost:8081/debugger-ui/ to http://192.168.XXXX.XXXX.xip.io:8081/debugger-ui/
source: https://github.com/facebook/react-native/issues/17618
I had same error, I just closed the browser and refreshed my simulator. It may open the browser window again with debugging window. But it takes care of the error. If not I suggest terminating your simulator and running the build commands again.
This can be solved by restarting JS debugging and closing existing debugger.
Close Chrome debugger session
On iOS, do:
CMD + CTRL + Z
Press Stop Remote JS Debugging
CMD + CTRL + Z Again
enable Remote JS Debugging
Almost the same on Android, but the difference is the keyboard command it is CMD + M on Mac or CTRL+M on Windows devices.
Close emulator.
Close node console which get opened after executing command react-native run-android.
Start emulator again.
Run project again.
Hope this help.
i just cleared my browser cache and my app cache and its working now
this error appears when you have
I installed chrome CORS extension and enabled the CORS then it worked, Even If I open chrome with disable security manually then also it didn't worked for me until I install the extension.
Aha! Found a better, less hacky solution. It seems when I upgraded Expo client on windows, it changed my default 'host'. Click the cog and change 'host' to 'LAN' to avoid CORS
I’m doing a React Native project. It has a bug.
The bug make the APP just exit(it can functional run a while, but suddenly...just gone). So it dose not report error. How can I find out where the problem is?
My APP used react-native-bluetooth-serial.
My code on Github
Are you running it on you simulator.
If that is so you have to use real device for testing it as simulators do not have access to bluetooth peripherals.
Hope this helps.
You can use Genymotion or real device to use bluetooth enabled app. To test your bug you can also use "Debug JS remotely" feature of react native dev tools.
To enable dev tools in your real device, shake your device and dev menu will appear. In emulator you can press Ctrl + M to enable dev menu. then you can choose "Debug JS remotely" which will open in chrome. If you are familiar with web development then you might have used "Inspect element" feature which will open dev tools.
The answers are right. You might be using a simulator which doesn't support bluetooth.
To know more about the crash you can check the logs natively. For android just run this inside your android folder
adb logcat
Or you can use
react-native log-ios
react-native log-android
As you see,when I open dev tool in chrome,It will soon turn into this red screen.If I do not open dev mode,it works, and console.log can log infomations in Xcode console.(this way is not use Xcode)
just open localhost:8081/debugger-ui and press Cmd+R in simulator, or dismiss this error, open developer menu in App and disable "Debug in Chrome" option
try to update your react-native version to more stable version may be 0.35 or 0.38.
this basically happens when react-native is not able to load the bundles into developer tool.