When the first paragraph contains a short introduction or summary of the page, we can style it emphasized and provide it as meta-data for search optimization.

A lead paragraph is optional, but to encourage its use, every file generated by hugo new with Perplex includes a placeholder.

Syntax

The attribute {.p-first} styles a paragraph emphasized. The additional more tag <!--more--> marks the paragraph as meta-description of the page. Search engines and other automatic web crawlers may use it, to categorize the page and produce a preview. If we don’t need the special styling from {.p-first}, we can add the more tag nonetheless.

Result

The first paragraph on this page is styled as lead paragraph. Because of an additional more tag its contents also gets included with a <meta>-tag in the <head> of the HTML page:

<meta name="description" content="When the first paragraph contains a short introduction or summary of the page, we can style it emphasized and provide it as meta-data for search optimization.">