Error: Dynamic server usage: Page couldn't be rendered statically because it used `cookies`
Full error message
Error: Dynamic server usage: Page couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/messages/dynamic-server-error
Solutionsource: official-docs \u2197
The page reads `cookies()`/`headers()` but Next tried to pre-render it. 1. Add `export const dynamic = 'force-dynamic'` at the top of the page/route file. 2. Or move the cookies() call into a Server Action or Route Handler. 3. For partial prerendering wrap the dynamic part in a `<Suspense>` boundary (experimental PPR).
API access
Get this solution programmatically \u2014 free, no authentication.
curl https://depscope.dev/api/error/1ddca84de8a2f1fa2ce60782c452eeff2b7b0c5f088dfe5efdee0aec29203cc2hash \u00b7 1ddca84de8a2f1fa2ce60782c452eeff2b7b0c5f088dfe5efdee0aec29203cc2