resolve_title#

technote.ext.metadata.resolve_title(doctree)#

Resolve the document’s title from its content.

The title is the plain text of the first title node in the doctree, which is the document’s top-level (H1) heading.

Parameters:

doctree (document) – The document’s doctree.

Returns:

The document’s title, or None if the document has no heading.

Return type:

str or None