1/**** DOCREADY ****/ 2// https://github.com/jfriend00/docReady 3(function(funcName, baseObj) { 4 "use strict"; 5 funcName = funcName || "dmDocReady"; 6 baseObj = baseObj || window; 7 var readyList = []; 8 var readyFired = false; 9 var readyEventHandlersInstalled = false; 10 11 function ready() { 12 if (!readyFired) { 13 readyFired = true; 14 for (var i = 0; i < readyList.length; i++) { 15 readyList[i].fn.call(window, readyList[i].ctx); 16 } 17 readyList = []; 18 } 19 } 20 21 function readyStateChange() { 22 if ( document.readyState === "complete" ) { 23 ready(); 24 } 25 } 26 27 baseObj[funcName] = function(callback, context) { 28 if (typeof callback !== "function") { 29 throw new TypeError("callback for dmDocReady(fn) must be a function"); 30 } 31 if (readyFired) { 32 setTimeout(function() {callback(context);}, 1); 33 return; 34 } else { 35 readyList.push({fn: callback, ctx: context}); 36 } 37 if (document.readyState === "complete" || (!document.attachEvent && document.readyState === "interactive")) { 38 setTimeout(ready, 1); 39 } else if (!readyEventHandlersInstalled) { 40 if (document.addEventListener) { 41 document.addEventListener("DOMContentLoaded", ready, false); 42 window.addEventListener("load", ready, false); 43 } else { 44 document.attachEvent("onreadystatechange", readyStateChange); 45 window.attachEvent("onload", ready); 46 } 47 readyEventHandlersInstalled = true; 48 } 49 } 50})("dmDocReady", window); 51 52async function dmFetchHtmlAsText(url) { 53 const response = await fetch (url); 54 return (await response).text(); 55} 56 57 58function dmReplaceObf( url, elm ) { 59 dmFetchHtmlAsText(url).then( (data) => { 60 elm.replaceWith(data); 61 }); 62} 63 64dmDocReady(function () { 65 $(".dmobfuscated").each(function() { 66 const url = $(this).attr('data-info'); 67 dmReplaceObf ( url, $(this) ); 68 }); 69}); 70
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.