Inline Markdown link doesn't render correctly when it's first thing on a line
malteneuss opened this issue · comments
malteneuss commented
I've come around a bug/quirk where Markdown link syntax doesn't render into a Html link (the output is the link syntax literally):
{-| Some multi-line comment that points to
[foo](https://en.wikipedia.org).
-}
someFunction :: Int -> Int
...
The issue only occurs when that link is the first on a line.
So, the issue is resolved when adding a space in front of [foo]
{-| Some multi-line comment that points to
[foo](https://en.wikipedia.org).
-}
or some other word
{-| Some multi-line comment that points
to [foo](https://en.wikipedia.org).
-}
The following also works correctly:
{-| [foo](https://en.wikipedia.org) within
some multi-line comment.
-}
Tested with Haddock version 2.24.2 within Stack version 2.7.3 x86_64 hpack-0.34.4 on NixOS 21.11, GHC version 8.10.7.
A project to test against can be found in https://github.com/malteneuss/hakyll/blob/5a7742a64bf9b41827138aeddd35b00504548971/lib/Hakyll/Core/Rules.hs#L147
Simon Jakobi commented
Duplicate of #774?!
malteneuss commented
Yes.