-
-
Save booc0mtaco/63fc3558054469685513feb188e9b014 to your computer and use it in GitHub Desktop.
Save images from chrome inspector network tab
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* right click on an entry in the network log, select Copy All as Har | |
| * type in console: x = [paste] | |
| * next, paste the following JS code into the console | |
| * copy the output, paste into a file (or `cat > image-list.txt`, paste output, and hit ^D on a new line) | |
| * then wget -i [that file] | |
| * `mime` can be full or partial matches, e.g., "image/" or "image/png" | |
| * TODO: regexp on mime param. | |
| */ | |
| (function(logObj, mime) { | |
| var results = []; | |
| logObj.log.entries.forEach(function (entry) { | |
| if (mime && entry.response.content.mimeType.indexOf(mime) === -1) return; | |
| results.push(entry.request.url); | |
| }); | |
| console.log(results.join('\n')); | |
| })(x, 'image/jpeg'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment