Examples
Layout
Elkjs Tree

Elkjs Tree

Like our dagre example, this example shows how you can integrate elkjs (opens in a new tab) with Svelte Flow for more advanced tree layouts. The code for this example builds a similar tree to the dagre example, but you can look at the reference here (opens in a new tab) to see what you can configure (hint: it's a lot).

<script lang="ts">
const data: string = "world";
</script>

<h1>Hello {data}</h1>

<style>
h1 {
  font-size: 1.5rem;
}
</style>
Read-only