@c15t/nextjs
Version:
Developer-first CMP for Next.js: cookie banner, consent manager, preferences centre. GDPR ready with minimal setup and rich customization.
1 lines • 391 B
JavaScript
let e=["cf-ipcountry","x-vercel-ip-country","x-amz-cf-ipcountry","x-country-code"],t=["x-vercel-ip-country-region","x-region-code"],c=[...e,...t,"accept-language","user-agent"];function r(r){let n={};for(let e of c){let t=r.get(e);t&&(n[e]=t)}let o=e.find(e=>n[e]);o&&(n["x-c15t-country"]=n[o]);let i=t.find(e=>n[e]);return i&&(n["x-c15t-region"]=n[i]),n}export{r as extractRelevantHeaders};