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

Index sitemap does not reference the generated sitemaps #301

Closed
jopesh opened this issue Feb 16, 2022 · 1 comment · Fixed by #302
Closed

Index sitemap does not reference the generated sitemaps #301

jopesh opened this issue Feb 16, 2022 · 1 comment · Fixed by #302
Assignees
Labels
bug Something isn't working

Comments

@jopesh
Copy link

jopesh commented Feb 16, 2022

Describe the bug
Upgraded from ^2.1.15 to ^2.4.1 and now the following happens on next build:

  • sitemap.xml and sitemap-0.xml are produced as expected.
  • sitemap-0.xml does have the expected content
  • sitemap.xml however yields:
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">

</sitemapindex>

Hence, not referencing the sitemap-0.xml. The configuration file has not been modified.

To Reproduce
Steps to reproduce the behaviour:

  1. Upgrade package from ^2.1.15 to ^2.4.1
  2. Run next build
  3. Validate the generated files

Expected behavior
Expected output of sitemap.xml would've been:

<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <sitemap>
    <loc>https://johnschmidt.de/sitemap-0.xml</loc>
  </sitemap>
</sitemapindex>

Additional context
Contents of the configuration file:

/** @type {import('next-sitemap').IConfig} */

module.exports = {
  siteUrl: "https://johnschmidt.de",
  generateRobotsTxt: true,
}
@jopesh jopesh added the bug Something isn't working label Feb 16, 2022
@iamvishnusankar
Copy link
Owner

@jopesh Thanks for reporting this. Fixed #302

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants