When using getDraftData, the following error occurs during build time, preventing SSG:
Error: Dynamic server usage: Route /[...slug] couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/messages/dynamic-server-error
No errors should occur during build time, and SSG should function properly.
Package containing the bug
next-drupal (NPM package)
Describe the bug
When using getDraftData, the following error occurs during build time, preventing SSG:
Expected behavior
No errors should occur during build time, and SSG should function properly.
Steps to reproduce:
https://github.com/chapter-three/next-drupal/tree/basic-starter%402.0.0/starters/basic-starter
https://github.com/chapter-three/next-drupal/blob/next-drupal%402.0.0/starters/basic-starter/app/%5B...slug%5D/page.tsx#L127