-
So I'm using I could begin the link url with a So what I really want is for my link to basically be this pseudocode, but I haven't been able to find a way because the markdown source files can't 'see' the config values:
Any ideas? I thought of somehow pulling |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
You're at Markdown processing stage, not at template rendering which comes later, so moving anything inside def on_page_markdown(markdown, *, page, config, files):
return markdown.replace("__DOCS_DIR__", config.docs_dir) Note that I'm not sure if that's already sufficient to resolve the correct link location. Some fiddling might be necessary 😅 You should the be able to use this placeholder in your Markdown then: [My Destination](__DOCS_DIR__/rest/of/path.md) |
Beta Was this translation helpful? Give feedback.
-
This was solved by MkDocs in version 1.6, with Validation of absolute links.
|
Beta Was this translation helpful? Give feedback.
This was solved by MkDocs in version 1.6, with Validation of absolute links.