To make it easier for the Performance inspector plugin lets expose
the total size in bytes from inspect, so it can be used to calculate
the total size and graph the data.
There's one drawback with the fix: the total size is
also included in the console log, adding one extra field when you
log the data as a table. The method is generic that logs the data
and I don't want to change that.
Bug: T129319
Change-Id: Ic7ccbe624f07443942974a71f8a0b3f94074bb55
// Convert size to human-readable string.
$.each( modules, function ( i, module ) {
+ module.sizeInBytes = module.size;
module.size = humanSize( module.size );
} );