window['adrum-start-time'] = new Date().getTime(); (function (config) { const APPD_URL = 'https://eumnpe.ms.ca.npe'; var search_string = window.location.href.toLowerCase() if (search_string.indexOf("/scheduling") != -1) { config.appKey = 'EUM-AAB-AVM'; } else if(search_string.indexOf("/crisis-intake") != -1) { config.appKey = 'EUM-AAB-AVM'; } else if(search_string.indexOf("/step") != -1) { config.appKey = 'EUM-AAB-AVS'; } else if(search_string.indexOf("/online-passport-renewal") != -1) { config.appKey = 'EUM-AAB-AVJ'; } else { config.appKey = 'EUM-AAB-AVP'; } config.useHTTPSAlways = true; config.adrumExtUrlHttps = APPD_URL; config.beaconUrlHttps = APPD_URL; // this is url for beacon config.spa = {"spa2": true}; config.xd = {enable: true}; if (typeof userData !== 'undefined') { (function (info) { (function (page) { page.userData = userData; }) (info.PageView || (info.PageView = {})); }) (config.userEventInfo || (config.userEventInfo = {})) } })(window['adrum-config'] || (window['adrum-config'] = {})); // appd basic snippet code do not change window.dataLayer = window.dataLayer || []; window.addEventListener('pushstate', function (e) { ADRUM.setVirtualPageName(e.target.document.URL) // to send the pageview with the new SPA changed URL }, false);