Skip to content

Instant navigation and mkdocs-redirect do not play well? #2517

Answered by squidfunk
hellt asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for reporting. The redirect should happen, yes. This might be an edge case to catch in instant navigation, which expects all entries in sitemap.xml to be actual pages. If you could provide a minimal reproducible example in a new issue, I can look into it.

EDIT: In fact, it should be as easy as checking for <meta http-equiv=refresh ... /> and injecting that into the current page, as that's what the redirect plugin adds:

<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>Redirecting...</title>
    <link rel="canonical" href="/mkdocs-material/insiders/">
    <meta name="robots" content="noindex">
    <script>var anchor=window.location.hash.substr(1);location.h…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@hellt
Comment options

@squidfunk
Comment options

Answer selected by squidfunk
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants