1.1 KiB
1.1 KiB
| layout | title | description | keywords | author | nav | category | image | twitterdescription |
|---|---|---|---|---|---|---|---|---|
| default | Chrome HAR | Create Chrome HAR files bases on events from the Chrome Debugging Protocol. | Chrome HAR, documentation, web performance | Peter Hedenskog | documentation | chrome-har | https://www.sitespeed.io/img/sitespeed-2.0-twitter.png |
Chrome-HAR
{:.no_toc}
Create HAR files based on Chrome Debugging Protocol data.
Code originally extracted from Browsertime, initial implementation inspired by Chromedriver_har.
Introduction
Chrome-HAR is for tool makers: Get the log from the Chrome Debugging Protocol and use Chrome-HAR to parse it to a HAR.
Example
Convert your messages to a HAR file.
const parser = require('chrome-har');
// you already have the message from Chrome Debugging Protocol
parser.harFromMessages(messages))
.then(har => {
// do whatever you want with the HAR file
})