wordalle / static /_app /immutable /chunks /preload-helper-8235996a.js
radames's picture
add static build
00577d2
raw
history blame
621 Bytes
const a="modulepreload",o={},u="/embed/huggingface-projects/wordalle/static/_app/immutable/",f=function(s,n){return!n||n.length===0?s():Promise.all(n.map(e=>{if(e=`${u}${e}`,e in o)return;o[e]=!0;const t=e.endsWith(".css"),i=t?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${e}"]${i}`))return;const r=document.createElement("link");if(r.rel=t?"stylesheet":a,t||(r.as="script",r.crossOrigin=""),r.href=e,document.head.appendChild(r),t)return new Promise((l,c)=>{r.addEventListener("load",l),r.addEventListener("error",()=>c(new Error(`Unable to preload CSS for ${e}`)))})})).then(()=>s())};export{f as _};