1import{a as q,u as z,h as f}from"./pAIW8bm9.js";import{z as w,A as x,B as m,C as c,D as A}from"./Cvj6YUp_.js";function C(e){const n=[c(e.method)?.toUpperCase()||"GET",c(e.baseURL)];for(const t of[e.query||e.params]){const a=c(t);if(!a)continue;const s={};for(const[o,r]of Object.entries(a))s[c(o)]=c(r);n.push(s)}if(e.body){const t=c(e.body);if(!t)n.push(f(t));else if(t instanceof ArrayBuffer)n.push(f(Object.fromEntries([...new Uint8Array(t).entries()].map(([a,s])=>[a,s.toString()]))));else if(t instanceof FormData){const a={};for(const s of t.entries()){const[o,r]=s;a[o]=r instanceof File?r.name:r}n.push(f(a))}else if(A(t))n.push(f(w(t)));else try{n.push(f(t))}catch{console.warn("[useFetch] Failed to hash body",t)}}return n}const b=q({name:"createUseFetch",factory(e={}){function n(t,a,s){const[o={},r]=typeof a=="string"?[{},a]:[a,s],u=m(()=>c(t)),l=m(()=>c(o.key)||"$f"+f([r,typeof u.value=="string"?u.value:"",...C(o)]));if(!o.baseURL&&typeof u.value=="string"&&u.value[0]==="/"&&u.value[1]==="/")throw new Error('[nuxt] [useFetch] the request URL must not start with "//".');const y=typeof e=="function"?e(o):e,{server:_,lazy:v,default:F,transform:U,pick:g,watch:i,immediate:D,getCachedData:O,deep:L,dedupe:j,timeout:k,...h}={...typeof e=="function"?{}:y,...o,...typeof e=="function"?y:{}},p=w({...x,...h,cache:typeof h.cache=="boolean"?void 0:h.cache}),R={server:_,lazy:v,default:F,transform:U,pick:g,immediate:D,getCachedData:O,deep:L,dedupe:j,timeout:k,watch:i===!1?[]:[...i||[],p]};return z(i===!1?l.value:l,(T,{signal:$})=>(o.$fetch||globalThis.$fetch)(u.value,{signal:$,...p}),R)}return n}});b.__nuxt_factory();b.__nuxt_factory({lazy:!0,_functionName:"useLazyFetch"});function E(e){return new URL(globalThis.location.href)}const d=e=>e.endsWith("/")?e:`${e}/`,G=e=>{if(typeof window<"u"&&window.location?.pathname)return d(window.location.pathname);try{const n=E();if(n?.pathname)return d(n.pathname)}catch{}return"/"};export{G as g};
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.