You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature request]: official plugin for auto-generating title and description from Markdown content #470
I would like to propose an official plugin for Comark that automatically extracts and populates title and description into the document metadata when they are missing from the Frontmatter.
If a file does not explicitly declare these fields in its Frontmatter, the plugin should automatically infer:
title: From the first h1 (# Title) in the document.
description: From the text of the first paragraph.
Motivation
Ecosystem parity & smooth migration: MDC (@nuxtjs/mdc) automatically handles title and description extraction. Providing an official plugin for Comark ensures feature parity and makes migrating existing projects effortless.
Preventing redundant logic: Frontmatter fallback extraction is a standard requirement for content sites, blogs, and documentation. An official plugin avoids every developer having to write and maintain custom AST traversal logic.
Better DX for dynamic content: Content generated by third-party tools, CMS exports, or AI workflows often lacks YAML Frontmatter. Having an official, well-maintained plugin ensures consistent metadata handling across all Comark projects.
Activity