Skip to main content

Home > @jsplumbtoolkit/core > JsPlumbToolkit > addNewPort

JsPlumbToolkit.addNewPort() method

Adds a new Port to some Node. This will call the current portFactory to get the data for a new Port.

Signature:

addNewPort(obj: string | Node | Group, type: string, portData?: ObjectData, doNotFireEvent?: boolean): void;

Parameters

ParameterTypeDescription
objstring | Node | Groupnode/group or id of the node/group to add a new Port to.
typestringType of Port to add.
portDataObjectDataData to pass to the PortFactory.
doNotFireEventboolean

Returns:

void