[Bug] sitemap contains redirect page entries #8821
Labels
bug
A bug to fix
static-site
Produce static HTML output ready for publishing to hosts like GitHub pages
Describe the bug
Sitemap.xml contains redirect page entries.
Redirect page should not be included in sitemap's entry.
To Reproduce
Steps to reproduce the behavior:
https://dotnet.github.io/docfx/sitemap.xml
)https://dotnet.github.io/docfx/tutorial/walkthrough/walkthrough_create_a_docfx_project_2.html
) exists.Expected behavior
redirect page is not appear in sitemap entries.
How to fix this problem
It seems
SitemapGenerator
PostProcessor can't access FileModel metadata directly as described below.I want to making modifications in the following directions, but if you have a better idea, please let us know.
<meta http-equiv="refresh"
tag existence. and save metadata toOutputFileInfo
.Pros
Cons
HtmlPostProcessor
is executed in first priority<meta http-equiv="refresh"
.For SEO optimization, redirect may be implemented at server side feature.
(Example: https://www.statiq.dev/guide/web/content-files/redirects)
The text was updated successfully, but these errors were encountered: