[].forEach.call(document.querySelectorAll('img'), function (img) { if (/\.gif/i.test(img.src)) img.remove() })