binyamin / eleventy-garden

:seedling: A starter site for building a mind garden with eleventy
https://eleventy-garden.netlify.app
MIT License
450 stars 48 forks source link

Backlinks behave differently in local and on github page #87

Closed jrekier closed 1 year ago

jrekier commented 2 years ago

Describe the bug The expected backlink appears in local (image 1), but not when pushed to my (project) github page. Interestingly, another backlink appears in that case (image 2).

Screenshots image image

Additional context My page contains two notes named "First note" and "Inertial Waves and Inertial Modes" that both link to a third note named "Poincaré equation". Only the first note appears in the list of backlinks online. On the other hand, only the second appears in local. That does not seem to be collections issue. I could not find the reason for this behavior.

binyamin commented 2 years ago

I assume that it's related to how the GitHub Pages site exists in a sub-directory. Unfortunately, I have no idea what's going on. If you could create a minimal test-case, that might help me debug this.

Also, I recently made an Eleventy plugin which encapsulates this template's logic. Maybe it will work differently. It just plugs into an existing eleventy site. https://github.com/binyamin/eleventy-plugin-backlinks

jrekier commented 2 years ago

Thanks for your reply :) It is hard to build a minimal test-case since the behavior happens when the repo is pushed online, so you would need to create a minimal test-github page to go with it. I can do it if that helps!

I'll also have a look at the plugin. Thanks for that too.

binyamin commented 2 years ago

@jrekier Yeah, I guess you would need a GitHub page to go with it. If you can do that, it would be great.

jrekier commented 1 year ago

Hi @binyamin,

I'm finally getting back to this. I haven't had time to build a GitHub page from the ground up, but I think you should be able to reproduce the issue using my actual page: https://github.com/jrekier/mind-garden

I have tried to look at your plugin but I'm having difficulty with the practical implementation.

Thanks for your help,