UNPKG

@xyflow/svelte

Version:

Svelte Flow - A highly customizable Svelte library for building node-based editors, workflow systems, diagrams and more.

16 lines (15 loc) 318 B
import { useStore } from '../store'; /** * Hook for receiving the current connection. * * @public * @returns Current connection as a signal */ export function useConnection() { const { connection } = $derived(useStore()); return { get current() { return connection; } }; }