(nodes: MdzNode[], components: Record<string, string>, elements: ReadonlySet<string>, base?: string | undefined): MdzToSvelteResult Converts an array of MdzNode to a Svelte markup string.
Each node type produces output matching what MdzNodeView.svelte renders at runtime. Collects required imports and flags unconfigured component/element references.
nodes
parsed mdz nodes to render
MdzNode[]components
Component name to import path mapping (e.g., {Alert: '$lib/Alert.svelte'})
If content references a component not in this map, has_unconfigured_tags is set.
Record<string, string>elements
Allowed HTML element names (e.g., new Set(['aside', 'details']))
If content references an element not in this set, has_unconfigured_tags is set.
ReadonlySet<string>base?
Base path for resolving relative links (e.g., '/docs/mdz/')
When provided, relative references (./, ../) are resolved to absolute paths
and passed through resolve(). Trailing slash recommended.
string | undefinedreturns
MdzToSvelteResult