Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions src/content/docs/en/guides/integrations-guide/sitemap.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,24 @@ The resulting sitemap looks like this:
...
```

### prefix

By default `sitemap-index.xml` and `sitemap-*.xml` are created in the output directory. By setting `prefix`, You can change the filename.
Comment thread
ktym4a marked this conversation as resolved.
Outdated

```js title="astro.config.mjs" ins={8}
import { defineConfig } from 'astro/config';
import sitemap from '@astrojs/sitemap';

export default defineConfig({
site: 'https://stargazers.club',
integrations: [
sitemap({
prefix: 'astrosite-', // output files will be `astrosite-index.xml` and `astrosite-*.xml`.
}),
],
});
```

## Examples

* The official Astro website uses Astro Sitemap to generate [its sitemap](https://astro.build/sitemap-index.xml).
Expand Down