demo · v130
expectedImprovement: gone, here's the replacement
The probe below detects whether DelegatedInkTrailPresenter.expectedImprovement still exists and shows the recommended replacement — using the regular EventTiming performance entries to measure your actual pen input latency. Draw on the canvas to populate the measurements.
the code
// REMOVED in v130:
// presenter.expectedImprovement // → undefined
// REPLACEMENT — measure real input latency with PerformanceEventTiming:
new PerformanceObserver((list) => {
for (const e of list.getEntries()) {
if (e.name === "pointerdown" || e.name === "pointermove") {
console.log(`${e.name} input delay: ${(e.processingStart - e.startTime).toFixed(2)} ms`);
}
}
}).observe({ type: "event", durationThreshold: 0, buffered: true });