Skip to main content

Function: frontMatter()

frontMatter(metadata, format): string

Function to create formatted front matter for markdown files.

Parameters

metadata: Record<string, unknown>

The metadata to include in the front matter.

format: "json" | "yaml" = 'yaml'

The format to output the front matter in. Defaults to 'yaml'.

Returns

string

Defined in

lib/markdown.ts:809