question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Download all images on the page

See original GitHub issue

/download-images command in the search bar runs the following plugin script

const run = async () => {
  const dirHandle = await window.showDirectoryPicker();
  const imgs = document.querySelectorAll("img");
  let i = 0;

  imgs.forEach(async (img) => {
    const url = img.src;
    const name = `img-${i}.png`;
    i++;

    try {
      console.log(`Fetching ${url}`);
      const response = await fetch(url);

      console.log(`Saving to ${name}`);

      const file = await dirHandle.getFileHandle(name, { create: true });
      const writable = await file.createWritable();
      await response.body.pipeTo(writable);
    } catch (err) {
      console.log(err);
    }
  });
};

run();

https://paul.kinlan.me/bookmarklet-to-download-all-images-on-a-page-with-the-file-system-api/

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:34 (21 by maintainers)

github_iconTop GitHub Comments

1reaction
aashu0148commented, Dec 30, 2020

Its done @argyleink Please review it 😃

Screenshot (43) Screenshot (44)

1reaction
argyleinkcommented, Dec 29, 2020

Vacation 😁

Read more comments on GitHub >

github_iconTop Results From Across the Web

Download All Images - Chrome Web Store
Easily save photos from Instagram, Google Images, etc. Download All Images is the #1 bulk image downloader with over 150K users world wide!...
Read more >
How to Download All Images on a Web Page at Once - wikiHow
1. Open Google Chrome or Microsoft Edge. If you have Google Chrome or Edge installed on your computer, you have a variety of...
Read more >
Image Extractor
A free tool to extract, view and download images from any website by using a virtual browser.
Read more >
Bulk Download All Images In A Web-Page Via FireFox ...
Go to the website having the images you want to download. · Right-click and select View Page Info View Page Info - Firefox...
Read more >
Download & Save All Images from web page in Chrome ...
Download & Save All Images from web page in Chrome & Firefox · 1. Open the desired webpage and let it load completely....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found