The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
Share cookies with dub.co
Steven Tey4bd55ce4f7b1
diff --git a/apps/web/ui/modals/provider.tsx b/apps/web/ui/modals/provider.tsxindex c4f7159eca..c6a3901b6f 100644--- a/apps/web/ui/modals/provider.tsx+++ b/apps/web/ui/modals/provider.tsx@@ -59,7 +59,12 @@ export default function ModalProvider({ children }: { children: ReactNode }) {const params = useParams() as { slug?: string };const { slug } = params;- const [hashes, setHashes] = useCookies<SimpleLinkProps[]>("hashes__dub", []);+ const [hashes, setHashes] = useCookies<SimpleLinkProps[]>("hashes__dub", [], {+ httpOnly: true,+ sameSite: "lax",+ domain: !!process.env.NEXT_PUBLIC_VERCEL_URL ? ".dub.co" : undefined,+ secure: !!process.env.NEXT_PUBLIC_VERCEL_URL,+ });useEffect(() => {if (hashes.length > 0) {