Sha256: 4a4e2ef68a18e42d2cfaa36a220fab2f1803788677d831e102faaff3c867184e
Contents?: true
Size: 1.94 KB
Versions: 5
Compression:
Stored size: 1.94 KB
Contents
{% if page.url != '/' %} {% if jekyll.environment == 'production' and site.adsId %} <script> const autoLoadDuration = 5; //In Seconds const eventList = ["keydown", "mousemove", "wheel", "touchmove", "touchstart", "touchend"]; const autoLoadTimeout = setTimeout(runScripts, autoLoadDuration * 1000); eventList.forEach(function (event) { window.addEventListener(event, triggerScripts, { passive: true }) }); function triggerScripts() { runScripts(); clearTimeout(autoLoadTimeout); eventList.forEach(function (event) { window.removeEventListener(event, triggerScripts, { passive: true }); }); } function runScripts() { document.querySelectorAll("script[delay]").forEach(function (scriptTag) { scriptTag.setAttribute("src", scriptTag.getAttribute("delay")); }); } </script> <script type="text/javascript" delay="/assets/js/ads.js"></script> {% endif %} {% if jekyll.environment == 'development' and site.adsId %} <script> const autoLoadDuration = 5; //In Seconds const eventList = ["keydown", "mousemove", "wheel", "touchmove", "touchstart", "touchend"]; const autoLoadTimeout = setTimeout(runScripts, autoLoadDuration * 1000); eventList.forEach(function (event) { window.addEventListener(event, triggerScripts, { passive: true }) }); function triggerScripts() { runScripts(); clearTimeout(autoLoadTimeout); eventList.forEach(function (event) { window.removeEventListener(event, triggerScripts, { passive: true }); }); } function runScripts() { document.querySelectorAll("script[delay]").forEach(function (scriptTag) { scriptTag.setAttribute("src", scriptTag.getAttribute("delay")); }); } </script> <script type="text/javascript" delay="/assets/js/ads.js"></script> {% endif %} {% endif %}
Version data entries
5 entries across 5 versions & 1 rubygems