If you need to exclude a link from the sitemap.xml file, which is located in the ./dist folder, this documentation will help you.
-
Open the file
./utils/getRoutes.js -
In the
IGNORE_ROUTESglobal variable add the link to be excluded. -
Important: The link must not have a slash(/) at the end of the line.
-
Run command
npm run build & npm run generate -
After running the commands, the
sitemap.xmlfile will be generated in the./distfolder -
The ignored link must not be in the sitemap.xml file.