Skip to Content
✨ Svelte Flow 1.0 is here! Rewritten for Svelte 5 with many new features and improvements.
ExamplesNodesAdd Node on Edge Drop

Add Node On Edge Drop

You can create a new node when you drop the connection line on the pane by using the onConnectStart and onConnectEnd handlers.

<script lang="ts"> import { SvelteFlowProvider } from '@xyflow/svelte'; import Flow from './Flow.svelte'; </script> <!-- You need the SvelteFlowProvider so you can useSvelteFlow --> <SvelteFlowProvider> <Flow /> </SvelteFlowProvider>
Last updated on