PageSourceSearch

https://tabulareditor.com/hubfs/hub_generated/template_assets/1/21…/1790849789124/template_auth.min.js

js tabulareditor.com collected 2026-10-02 04:20:18 UTC 2,949 bytes, 2 lines download raw bytes

1var productionConfig={stripePublicKey:"pk_live_51IpuslAvuF7GzwfBtesyZw4Kgg16An35DyYjey6jrSTa9m5UEFNlam7cS45C6vb19DfJKkbW8hng81rxfOn9SHc4009TGFc97W",apiBaseUrl:"https://hubspotapibackendprodapim.azure-api.net",apiPath:"webapi/",fetchJwtTokenPath:"/hs/serverless/authenticate",newsletterSubscribePath:"/hs/serverless/subscribe",hubSpotPortalId:"145497246",hubspotAssetsBaseUrl:"//145497246.fs1.hubspotusercontent-eu1.net/hubfs/145497246/raw_assets/public/tabulareditor-nimbly-lite-child-2024/assets-react",hubDbId:"97110203",hubDbApiBaseUrl:"https://api.hubapi.com",ssoOrigin:"https://account.tabulareditor.com"},config=productionConfig;function clearStaleTokenIfReturningFromSso(){config.ssoOrigin&&document.referrer.startsWith(config.ssoOrigin)&&(localStorage.removeItem("tabtoken"),localStorage.removeItem("tabtoken_expires"))}clearStaleTokenIfReturningFromSso();var _pendingTokenRequest=null;async function fetchToken(){return _pendingTokenRequest||(_pendingTokenRequest=(async()=>{try{const controller=new AbortController,timer=setTimeout(()=>{controller.abort()},15e3);let response;try{response=await fetch(config.fetchJwtTokenPath,{signal:controller.signal})}finally{clearTimeout(timer)}if(!response.ok)throw new Error("Failed to authenticate");const tokenData={token:(await response.json()).access_token,expiresAt:Date.now()+36e5};return localStorage.setItem("tabtoken",tokenData.token),localStorage.setItem("tabtoken_expires",tokenData.expiresAt.toString()),tokenData}catch(error){throw console.error("Authentication error:",error),error}finally{_pendingTokenRequest=null}})())}async function getToken(){const storedToken=localStorage.getItem("tabtoken"),expiresAtString=localStorage.getItem("tabtoken_expires"),expiresAt=expiresAtString?parseInt(expiresAtString,10):0,isExpired=Date.now()>=expiresAt-3e5;if(!storedToken||isExpired){const{token:token}=await fetchToken();return token}return storedToken}function _hasStandaloneModules(){return document.querySelectorAll(".standalone-react-module").length>0}function _initializeToken(){_hasStandaloneModules()||getToken()}function tokenInvalidationByLoginLogout(){document.addEventListener("click",event=>{if(event.target&&event.target instanceof Element){const link=event.target.closest("a");if(link){const href=link.href.toLowerCase();(href.includes("_hcms/mem/login")||href.includes("_hcms/mem/logout"))&&(localStorage.removeItem("tabtoken"),localStorage.removeItem("tabtoken_expires"))}}},{passive:!0})}"interactive"===document.readyState||"complete"===document.readyState?_initializeToken():document.addEventListener("DOMContentLoaded",_initializeToken),"interactive"===document.readyState||"complete"===document.readyState?tokenInvalidationByLoginLogout():document.addEventListener("DOMContentLoaded",tokenInvalidationByLoginLogout);
2//# sourceURL=https://145497246.fs1.hubspotusercontent-eu1.net/hubfs/145497246/hub_generated/template_assets/1/219168402636/1790849789124/template_auth.js

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.