In the past 24 hours you have created three posts on this forum related to the same thing:
- https://discourse.gohugo.io/t/22674/3
- https://discourse.gohugo.io/t/43803
- https://discourse.gohugo.io/t/43801 (this topic)
It seems like you have a fundamental misunderstanding of markdown links.
A markdown link has three components: link text, a link destination, and optionally a link title.
[Post 1](/posts/post-1 "My first post")
------ ------------- -------------
text destination title
The destination is a URL, either absolute or relative. The destination is not a file path.
In this post you describe a markdown render hook as a “hack.” It is not. A markdown render hook allows you to alter the way that markdown is rendered to HTML—it is a very powerful feature.
A well-constructed link render hook allows you to use file paths instead of URLs for link destinations. This makes your markdown portable to other systems, and provides link validation.
To address your questions, either (a) make sure your link destinations are valid URLs, or (b) implement a link render hook. More info here.