startPerformanceTracing method

Future<void> startPerformanceTracing(
  1. String? benchmarkName
)

Asks the local server to begin tracing performance.

This uses the chrome://tracing tracer, which is not available from within the page itself, and therefore must be controlled from outside using the DevTools Protocol.

Implementation

Future<void> startPerformanceTracing(String? benchmarkName) async {
  _checkNotManualMode();
  await _requestXhr(
    '/start-performance-tracing?label=$benchmarkName',
    method: 'POST',
    mimeType: 'application/json',
  );
}