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

Feature request: have backlinks detect standard links and not just zola (leading @) links #2733

Open
zmre opened this issue Dec 10, 2024 · 3 comments

Comments

@zmre
Copy link

zmre commented Dec 10, 2024

I use zola to publish my repository of notes. I link between notes using standard markdown with relative links like [Note Name](../otherdir/othernote) (no ending .md and no leading @). Backlinks only populate if you use the @/path/to/otherdir/othernote.md notation, but that notation breaks all my other tools. So in neovim, for example, when there's a path, I can use gf to go to that file. And my LSP detects if links are good or not and can autocomplete paths to files and their titles. All of that goes away with the non-standard link. My LSP also detects related notes by tracking backlinks, but of course if I switch to the Zola syntax to get that info into the rendered stuff, then I lose that info in the editor side.

So long story short, is it feasible to have backlinks populate with any link to a file and not just the zola-special absolute links? I'd really love to be able to navigate to related notes based on backlinks without having to use the special link syntax and then break the same functionality in other places...

I'm new to Zola but very happy with it so far so great work and thank you.

@Keats
Copy link
Collaborator

Keats commented Dec 12, 2024

The issue with not using the syntax is that and doing [Note Name](../otherdir/othernote) means that now, you cannot resolve a page markdown on its own. To get the backlinks, you would need to get all the URLs in your website and resolve them for every internal link. It's possible to do but not something I would do myself. It would also need to not affect performance in any way if it's added

@zmre
Copy link
Author

zmre commented Dec 12, 2024 via email

@Keats
Copy link
Collaborator

Keats commented Dec 12, 2024

Custom zola syntax + external links. Other links are not checked since they could refer to anything, including content not available at zola build time

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

2 participants