@mui/internal-benchmark 0.0.3-canary.13 → 0.0.3-canary.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.mjs +3 -3
- package/package.json +2 -2
- package/reactRecording.d.mts +1 -1
package/index.mjs
CHANGED
|
@@ -284,13 +284,13 @@ export function benchmark(name, renderFn, interactionOrOptions, maybeOptions) {
|
|
|
284
284
|
if (!isWarmup) {
|
|
285
285
|
for (const entry of timing.elementEntries) {
|
|
286
286
|
// Skip paints that happened while recording was paused. Attribute by the paint's
|
|
287
|
-
// `
|
|
288
|
-
if (!recording.activeAt(entry.
|
|
287
|
+
// `paintTime`, not by when the observer callback fired (which can lag the paint).
|
|
288
|
+
if (!recording.activeAt(entry.paintTime)) {
|
|
289
289
|
continue;
|
|
290
290
|
}
|
|
291
291
|
// The default sentinel is the base series; named markers become sub-series.
|
|
292
292
|
const id = entry.identifier === 'default' ? undefined : entry.identifier;
|
|
293
|
-
paint.record(entry.
|
|
293
|
+
paint.record(entry.paintTime - iterationStart, id !== undefined ? {
|
|
294
294
|
id
|
|
295
295
|
} : undefined);
|
|
296
296
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mui/internal-benchmark",
|
|
3
|
-
"version": "0.0.3-canary.
|
|
3
|
+
"version": "0.0.3-canary.15",
|
|
4
4
|
"author": "MUI Team",
|
|
5
5
|
"description": "Benchmark utilities for MUI projects. Internal package.",
|
|
6
6
|
"repository": {
|
|
@@ -68,5 +68,5 @@
|
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
70
|
},
|
|
71
|
-
"gitSha": "
|
|
71
|
+
"gitSha": "56783aecd7eeee1d4381c33fd5d160b9a1c8c292"
|
|
72
72
|
}
|
package/reactRecording.d.mts
CHANGED
|
@@ -5,7 +5,7 @@ export interface ReactRecordingControls {
|
|
|
5
5
|
readonly hadEmptyActiveWindow: boolean;
|
|
6
6
|
/**
|
|
7
7
|
* Whether recording was active at `time` (a `performance.now()` timestamp). Paint entries are
|
|
8
|
-
* observed asynchronously, so they are attributed by their `
|
|
8
|
+
* observed asynchronously, so they are attributed by their `paintTime` rather than by the
|
|
9
9
|
* recording state at the moment the observer callback happens to fire.
|
|
10
10
|
*/
|
|
11
11
|
activeAt(time: number): boolean;
|