Something went wrong. Try again.
a tool for shared writing and social publishing
Something went wrong. Try again.
TypeScript
12345678import { headers } from "next/headers";export async function getCurrentDeploymentDomain() { const headersList = await headers(); const hostname = headersList.get("x-forwarded-host"); let protocol = headersList.get("x-forwarded-proto"); return `${protocol}://${hostname}/`;}