mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-01-30 09:08:40 +08:00
[ReactNative] Update JS profiler to be compatible with Android
Summary: Use nativeTraceBeginSection and nativeTraceEndSection with a more dynamic signature to be compatible with Android.
This commit is contained in:
@@ -131,8 +131,8 @@ function setUpWebSockets() {
|
||||
}
|
||||
|
||||
function setupProfile() {
|
||||
console.profile = console.profile || GLOBAL.consoleProfile || function () {};
|
||||
console.profileEnd = console.profileEnd || GLOBAL.consoleProfileEnd || function () {};
|
||||
console.profile = console.profile || GLOBAL.nativeTraceBeginSection || function () {};
|
||||
console.profileEnd = console.profileEnd || GLOBAL.nativeTraceEndSection || function () {};
|
||||
require('BridgeProfiling').swizzleReactPerf();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user