-
-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
next/headers call prevent sitemap generation #692
Labels
Comments
Closing this issue due to inactivity. |
Running into this same issue with |
+1 |
Same here when |
+1 |
Please don't "+1", use the Github reactions feature |
Closing this issue due to inactivity. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
When
headers()
(imported from next/headers) is called in a layout.js or in a page.js file, next-sitemap doesn't generate.To Reproduce
Link to the repro: https://github.com/bastienrobert/next-sitemap-generation-with-headers-repro
Steps to reproduce the behavior:
pnpm create next-app
next sitemap
next-sitemap.config.js
fileheaders()
call (from next/headers) in layout.jspnpm build
pnpm postbuild
sitemap is empty
headers()
in layout.jspnpm build
pnpm postbuild
sitemap-0.xml is generated
Expected behavior
sitemap-0.xml
generation event if there's aheaders()
call.The text was updated successfully, but these errors were encountered: