Skip to main content

Function: collectFencedCodeBlocks()

function collectFencedCodeBlocks(text: string): readonly Readonly<{
content: string;
contentEnd: number;
contentStart: number;
end: number;
infoString: string;
start: number;
}>[];

Defined in: _internal/text-content-lint.ts:242

Collect fenced code blocks with their language/info string and raw content.

Parametersโ€‹

textโ€‹

string

Full Markdown/MDX source text.

Returnsโ€‹

readonly Readonly<{ content: string; contentEnd: number; contentStart: number; end: number; infoString: string; start: number; }>[]

Parsed fenced code block metadata.