sitespeedio / chrome-har

Create HAR files from Chrome Debugging Protocol data
MIT License
149 stars 50 forks source link

Fix README.md code example to correctly add response bodies to HARs #42

Closed michaelcypher closed 4 years ago

michaelcypher commented 5 years ago

The previous example didn't turn out to work. This example should compile and work correctly.

kmicol commented 5 years ago

@mikeecb Running into an issue with this line const addResponseBodyPromises: Array<Promise<void>> = [];

Am I missing anything?

complete error:

 const addResponseBodyPromises:  Array<Promise<void>> = [];
      ^^^^^^^^^^^^^^^^^^^^^^^

SyntaxError: Missing initializer in const declaration
kmicol commented 5 years ago

@mikeecb Actually after setting addResponseBodyPromises = [] everything appears to be working as intended. Thanks again!!!!!!!