---
export const prerender = false; // since we're reading cookies

import { getPreferencesServer } from '@/utils/docs/preferences';
import { resolveIndexRedirect } from '@/utils/docs/routing';

// astro check can't see usage inside return statements in frontmatter (false positive ts(6133))
const preferences = getPreferencesServer(Astro.cookies);
const { url } = resolveIndexRedirect({ preferences, params: {} });

return Astro.redirect(url, 307);
---
