react-native profiling不显示JS线程

时间:2016-11-15 10:32:32

标签: react-native profiling tracing

我按照官方指南来描述我的JS:https://facebook.github.io/react-native/docs/android-ui-performance.html

但是当我得到结果时,我可以看到没有与js相关的代码:

profiling screenshot

知道发生了什么事吗?接口非常缓慢,占用100%的CPU,但我没有信息。

编辑:看起来使用最新的本地反应版本可以解决这个问题,我使用0.30.0看起来在0.34.0附近引入了一些相关更改

1 个答案:

答案 0 :(得分:5)

您可以在调试时使用debuggerWorker.js上的chrome profiler:

chrome profiler screenshot

调试时的分析不会给你最准确的结果,所以要小心。