{"repo":"iamvishnusankar/next-sitemap","free":true,"listed":false,"github":"https://github.com/iamvishnusankar/next-sitemap","clone":"git clone https://github.com/iamvishnusankar/next-sitemap.git","description":"Sitemap generator for next.js. Generate sitemap(s) and robots.txt for all static/pre-rendered/dynamic/server-side pages.","language":"TypeScript","stars":3744,"topics":["nextjs","react","typescript","seo","sitemap","sitemap-generator","next-sitemap"],"license":"MIT","category":"saas-starters-boilerplates","readme_excerpt":"Table of contents - Getting started - Installation - Create config file - Building sitemaps - Custom config file - Building sitemaps with pnpm - Index sitemaps - Splitting large sitemap into multiple files - Configuration Options - Custom transformation function - Full configuration example - Generating dynamic/server-side sitemaps - Typescript JSDoc Getting started Installation Create config file next-sitemap requires a basic config file ( next-sitemap.config.js ) under your project root ✅ next-sitemap will load environment variables from .env files by default. Building sitemaps Add next-sitemap as your postbuild script Custom config file You can also use a custom config file instead of next-sitemap.config.js . Just pass --config .js to build command (Example: custom-config-file) Building sitemaps with pnpm When using pnpm you need to create a .npmrc file in the root of your project if you want to use a postbuild step: Index sitemaps (Optional) 📣 From next-sitemap v2.x onwards, sitemap.xml will be Index Sitemap. It will contain urls of all other generated sitemap endpoints. Index sitemap generation can be turned off by setting generateIndexSitemap: false in next-sitemap config file. (This is useful for small/hobby sites which does not require an index sitemap) (Example: no-index-sitemaps) Splitting large sitemap into multiple files Define the sitemapSize property in next-sitemap.config.js to split large sitemap into multiple files. Above is the minimal configuration to spli","default_branch":null,"files":null,"tree":[],"storefront":"/r/iamvishnusankar","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/iamvishnusankar/next-sitemap/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}