Make links work both in GitHub preview as well as the site

I want to make the links to pages work both in Github previews and in the site.

I have a strong feeling that this might be accomplished by render-link but I somehow am not able to it.

Let’s say I have the following:

blogs ----- blog1.md
        |
        --- blog2.md

I want to link blog1 in blog2. So, I want to do as such [blog 1](blog2.md) This would work fine on Github preview but won’t in HUGO.
How should I process the .Destination? Or any other way to do it?

Thanks
Yash

Didn’t I post a link to a project in another similar thread of yours?

1 Like

Ah okay, I thought it was just for the image part since I looked at it when I was searching for images. I should have looked there too, my bad!

Anyways, thanks for the reply and the amazing example!!

For the purpose of others who might land here, this is the thread

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.