Skip to content

Commit 9fe36be

Browse files
alexeylangfacebook-github-bot-7
authored andcommitted
Log JSBundleRequireTime and JSAppRequireTime.
Reviewed By: javache Differential Revision: D2590707 fb-gh-sync-id: 4c306342b5725aaaac1d8fa0257ef860e446b0d4
1 parent cf0a282 commit 9fe36be

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

Libraries/Utilities/PerformanceLogger.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,11 +71,21 @@ var PerformanceLogger = {
7171
timespans[key].endTime - timespans[key].startTime;
7272
},
7373

74-
clearTimespans() {
74+
clear() {
7575
timespans = {};
7676
extras = {};
7777
},
7878

79+
clearExceptTimespans(keys) {
80+
timespans = Object.keys(timespans).reduce(function(previous, key) {
81+
if (keys.indexOf(key) !== -1) {
82+
previous[key] = timespans[key];
83+
}
84+
return previous;
85+
}, {});
86+
extras = {};
87+
},
88+
7989
getTimespans() {
8090
return timespans;
8191
},

0 commit comments

Comments
 (0)