Hey All,
I ran into this strange instance where for each page of a website, Hugo generates an empty paragraph element at the start and end of the content output with {{ .Content }}
. Below is an example of what one of the Markdown files look like.
---
title: Page-specific title goes here.
keywords: Page keywords go here.
description: Page meta description goes here.
---
{{< pricing >}}
{{< plans >}}
{{< testimonials >}}
{{< faq >}}
{{< cta-card >}}
However, if I change the above to the following, the problem no longer occurs.
---
title: Page-specific title goes here.
keywords: Page keywords go here.
description: Page meta description goes here.
---
{{< pricing >}}
<!-- this line is intentional to stop Hugo from starting and ending the content with empty paragraph tags -->
{{< plans >}}
{{< testimonials >}}
{{< faq >}}
<!-- this line is intentional to stop Hugo from starting and ending the content with empty paragraph tags -->
{{< cta-card >}}
I would love to understand why this is the case. I assumed it was because there is an empty line after the frontmatter and at the end of the file, but removing those did not solve the problem.
NOTE: The comments are not required. They are merely added to highlight the difference.