HUGO

Relative Markdown Links - Markdown Render Hooks

The minimal example for relative markdown links:

[My Article](../my-article/index.md)

Template: /layouts/_default/_markup/render-link.html

<a href="{{ (.Page.GetPage .Destination).RelPermalink | safeURL }}">{{ .Text | safeHTML }}</a>

For more complex example in the test project, follow: https://github.com/bep/portable-hugo-links

2 Likes