The Tracing class exposes the tracing audit interface.
export declare class Tracing
You can use tracing.start
and tracing.stop
to create a trace file which can be opened in Chrome DevTools or timeline viewer.
The constructor for this class is marked as internal. Third-party code should not call the constructor directly or create subclasses that extend the Tracing
class.
await page.tracing.start({path: 'trace.json'});
await page.goto('https://www.google.com');
await page.tracing.stop();
Method | Modifiers | Description |
---|---|---|
[start(options)](./puppeteer.tracing.start.md) | Starts a trace for the current page. **Remarks:** Only one trace can be active at a time per browser. | |
[stop()](./puppeteer.tracing.stop.md) | Stops a trace started with the `start` method. |