Lazy Loading Image Replacer

12/11/2024, 11:27:58

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(У мене вже є менеджер скриптів, дайте мені встановити його!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name        Lazy Loading Image Replacer
// @namespace   Violentmonkey Scripts
// @match       https://mangapill.com/chapters/*/*
// @grant       none
// @version     1.0
// @author      a0fefd
// @description 12/11/2024, 11:27:58
// ==/UserScript==
let stuff = document.getElementsByTagName("picture");
let stuff2 = [];
for (let i = 0; i < stuff.length; i++) {
    let src = stuff[i].children[0].getAttribute("data-src");
    stuff2[i] = document.createElement("img");
    stuff[i].appendChild(stuff2[i]);
    stuff2[i].src = src;
    stuff2[i].height = stuff[i].children[0].height;
    stuff2[i].width = stuff[i].children[0].width;
    stuff[i].children[0].remove();
}