Skip to main content

validate_post_document

Function validate_post_document 

Source
pub fn validate_post_document(
    path_label: impl Into<String>,
    contents: &str,
    collection: PostCollection,
) -> Result<PostDocument, ContentValidationErrors>
Expand description

Validate one Markdown post without requiring its diagnostic label to be a managed-tree path.

The supplied collection still controls draft semantics. Intrinsic metadata checks and conflicts among the post’s own slug and aliases are enforced, while logical placement, collection-directory, and filename checks are deliberately skipped.