Skip to content
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

@astrojs/sitemap does not always output sitemaps to dist/ #4919

Closed
evadecker opened this issue Oct 2, 2023 · 2 comments · Fixed by withastro/astro#8844
Closed

@astrojs/sitemap does not always output sitemaps to dist/ #4919

evadecker opened this issue Oct 2, 2023 · 2 comments · Fixed by withastro/astro#8844
Labels
improve documentation Enhance existing documentation (e.g. add an example, improve description)

Comments

@evadecker
Copy link
Contributor

evadecker commented Oct 2, 2023

📚 Subject area/topic

Integrations

📋 Page(s) affected (or suggested, for new content)

https://docs.astro.build/en/guides/integrations-guide/sitemap/

📋 General description or bullet points (if proposing new content)

The @astrojs/sitemap docs currently state (emphasis mine):

Now, build your site for production via the astro build command. You should find your sitemap under dist/ for both sitemap-index.xml and sitemap-0.xml!

However, this is not always true. When using the Vercel adapter, files are output to .vercel/output/static/ instead of dist/. I'm not sure if other adapters also have output directories which diverge from dist/.

It took me awhile to understand why the CLI was saying @astrojs/sitemap: "sitemap-index.xml" is created. but nothing was displaying in /dist as the docs said they should.

🖥️ Reproduction in StackBlitz (if reporting incorrect content or code samples)

https://stackblitz.com/edit/github-fuztr3?file=src%2Fpages%2Findex.astro

@evadecker evadecker added the improve documentation Enhance existing documentation (e.g. add an example, improve description) label Oct 2, 2023
@evadecker
Copy link
Contributor Author

As a followup, it would be excellent to improve the command line output for @astrojs/sitemap to specify where the sitemap was output.

Currently, this is all you get:

image

@evadecker
Copy link
Contributor Author

Quality of life update to the CLI tracked here: withastro/astro#8824

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improve documentation Enhance existing documentation (e.g. add an example, improve description)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant