This component uses the [svelte:self API](https://svelte.dev/docs#svelte_self) to render the [UnorderedList](/components/UnorderedList) and [OrderedList](/components/OrderedList) components with tree structured data. A child node can render text, a link, HTML content, and other child nodes.
In version 0.86.0, the children prop was renamed to nodes for Svelte 5 compatibility.
HTML content provided via the html prop is not sanitized.
## Unordered The `nodes` prop accepts an array of child nodes. By default, the list type is unordered. ## Ordered Set `type` to `"ordered"` to use the ordered list variant. ## Ordered (native styles) Set `type` to `"ordered-native"` to use the native styles for an ordered list. ## Flat data structure If working with a flat data structure, use the `toHierarchy` utility to convert a flat data structure into a hierarchical array accepted by the `nodes` prop.