Use a lightweight cookie (multica_logged_in) + Next.js 16 proxy to 302-redirect authenticated users visiting / straight to /issues. Unauthenticated visitors (and search engine crawlers) continue to see the full landing page with zero flash. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
9 lines
263 B
TypeScript
9 lines
263 B
TypeScript
const COOKIE_NAME = "multica_logged_in";
|
|
|
|
export function setLoggedInCookie() {
|
|
document.cookie = `${COOKIE_NAME}=1; path=/; max-age=31536000; samesite=lax`;
|
|
}
|
|
|
|
export function clearLoggedInCookie() {
|
|
document.cookie = `${COOKIE_NAME}=; path=/; max-age=0`;
|
|
}
|