Skip to Content
Svelte Flow 2 is out! Read the announcement →
ReferenceTypes

OnBeforeConnect

Source on GitHub 

The OnBeforeConnect type is a callback function that is called before a connection is created. It can prevent the connection or modify it by returning false or a modified connection.

type OnBeforeConnect = ( connection: Connection, ) => false | void | null | EdgeType | Connection;
Parameters:
NameTypeDefault
connectionConnection
Returns:
false | void | EdgeType | Connection | null