getMarkdownOutline

Returns the hierarchy of sections

getMarkdownOutline
(,
scope MarkdownSettings settings = null
)

Examples

import std.conv : to;
assert (getMarkdownOutline("## first\n## second\n### third\n# fourth\n### fifth") ==
	[
		Section(2, " first", "first"),
		Section(2, " second", "second", [
			Section(3, " third", "third")
		]),
		Section(1, " fourth", "fourth", [
			Section(3, " fifth", "fifth")
		])
	]
);

Meta