Skip to content

Instantly share code, notes, and snippets.

Created May 10, 2021
What would you like to do?
How to slow down the loading of iframes by adding Javascript
function init() {
var vidDefer = document.getElementsByTagName('iframe');
for (var i=0; i<vidDefer.length; i++) {
if(vidDefer[i].getAttribute('data-src')) {
} } }
window.onload = init;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment