Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Render page prior to splitting on summary #1667
This is my first contribution to Hugo so I expect it to be strongly critiqued as I learn the ropes!
The issue that I found, which I briefly mentioned here, is that the summary generation doesn't work correctly in some cases when Markdown is used.
Hugo splits the page based on the summary marker, and then renders the header separately. If users make use of the references facility that comes with Markdown, then all the links in the reference list at the bottom of the page are no present when the markdown is rendered. Eg:
With the links missing, the page ends up with Markdown creeping into the summary.
This PR contains an attempt at fixing this issue by rendering the page first. I don't think it's perfect, and so I would appreciate some commentary on what would be a better option. One thing that stands out for me is that the whitespace isn't trimmed due to blank lines being convered to
Thanks again for Hugo, I love it.
It looks like fixing this isn't going to be as simple as I thought. Forcing rendering before splitting wraps the
The cheap fix is to force the use of
Keen to hear some ideas on how best to resolve this. I'll mull over some options as well. Thanks!
ah, i see what you mean. i had my