RN 浏览器调试卡顿问题

来源:互联网 发布:网络电视机顶盒好不好 编辑:程序博客网 时间:2024/04/27 22:50

RN开发中,经常要用到浏览器进行调试,常用的有Chrome或者是FirefoxChrome下已经自带调试工具了,Firefox需要自行安装调试工具react-devtools,用Firefox浏览器打开添加即可,使用Chrome基本是很卡的,这里说一下引起的问题,确定是浏览器选项卡打开太多导致的。

解决方法

方法1

独立打开一个新的窗口浏览器,不和非调试的容器共用。

方法2
使用react-native-debugger

#mac下安装brew update && brew cask install react-native-debugger#打开工具open "rndebugger://set-debugger-loc?host=localhost&port=8081"

会打开此独立软件
debugger