Sitemap

Shipped is equipped with next-sitemap to automatically generate the sitemap.xml file on build.

Update the siteUrl in the next-sitemap configuration file

next-sitemap.config.js
/** @type {import('next-sitemap').IConfig} */
module.exports = {
  siteUrl: "https://myapp.com",  // <-- set your website url
  generateRobotsTxt: true, // (optional)
  // ...other options
};

To generate the sitemap, simply run

terminal
npm run build

To know all the possible options, see the documentation of next-sitemap

Last updated