Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expecting [[./a/index]] to return <a href="a/", get <a href="a/index" #53

Open
ooker777 opened this issue Oct 19, 2023 · 0 comments
Open

Comments

@ooker777
Copy link

With this mkdocs.yml:

site_name: test
plugins:
  - ezlinks:
        wikilinks: true

And this folder structure:

docs/ 
├── index.md 
└── a/ 
	└── index.md

After the build we will have:

site/ 
├── index.html
└── a/ 
	└── index.html

If in docs/index.md you have this content:

[[a/index]]
[[a/index.md]]
[[./a/index]]
[[./a/index.md]]

Then in site/index.html the html will be:

| docs/index.md    | site/index.html                                    | Correct? |
| ---------------- | -------------------------------------------------- | -------- |
| [[a/index]]      | <a href="a/" title="a/index">a/index</a>           | ✔        |
| [[a/index.md]]   | <a href="a/" title="a/index.md">a/index.md</a>     | ✔        |
| [[./a/index]]    | <a href="a/index" title="./a/index">./a/index</a>  | ❌       |
| [[./a/index.md]] | <a href="a/" title="./a/index.md">./a/index.md</a> | ✔        |

At the same time Mkdocs will notice this:

INFO    -  Doc file 'index.md' contains an
           unrecognized relative link
           'a/index', it was left as is. Did  
           you mean 'a/index.md'?
@ooker777 ooker777 changed the title [[./a/index]] returns a/index, not a/ Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Oct 19, 2023
@ooker777 ooker777 changed the title Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Oct 19, 2023
@ooker777 ooker777 changed the title Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Oct 19, 2023
@ooker777 ooker777 changed the title Expecting [[./a/index]] to returns <a href="a/", get <a href="a/index" Expecting [[./a/index]] to return <a href="a/", get <a href="a/index" Oct 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant