1// public/ga4.js 2(() => { 3 const MEASUREMENT_ID = "G-T631MTG4Y5"; 4 const ATTRIBUTION_CAPTURE_URL = 5 window.CLUTCH_ATTRIBUTION_CAPTURE_URL || 6 "https://clutch-link-resolver-production.up.railway.app/api/attribution/capture"; 7 8 window.CLUTCH_ATTRIBUTION_CAPTURE_URL = ATTRIBUTION_CAPTURE_URL; 9 10 const attributionScript = document.createElement("script"); 11 attributionScript.defer = true; 12 attributionScript.src = "/attribution.js"; 13 document.head.appendChild(attributionScript); 14 15 // Load gtag.js 16 const s = document.createElement("script"); 17 s.async = true; 18 s.src = 19 "https://www.googletagmanager.com/gtag/js?id=" + 20 encodeURIComponent(MEASUREMENT_ID); 21 document.head.appendChild(s); 22 23 // Init gtag 24 window.dataLayer = window.dataLayer || []; 25 function gtag() { 26 window.dataLayer.push(arguments); 27 } 28 window.gtag = window.gtag || gtag; 29 30 gtag("js", new Date()); 31 32 // Send page_view for THIS document 33 gtag("config", MEASUREMENT_ID, { 34 page_title: document.title, 35 page_path: location.pathname, 36 page_location: location.href, 37 }); 38})();
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.