Arrow icon
See all demos

Connecting nodes by dragging and dropping

Have you ever wondered how to create a new connection when the user drags one element over another, or over a link that connects two elements with enough space between them? Or how to automatically place a new element next to the destination element and let the user choose the direction in which to place it? Check out this demo to see how you can achieve both scenarios, using SVG previews to help the user understand the impact of each drop action.
Demo instructions
Create new connections by dragging and dropping elements from the stencil onto other elements on the paper, or onto a link between two elements with sufficient distance.

Made with JointJS+

The source code of this demo is available as part of the JointJS+ commercial license. Don't have a license yet? Start a trial and use the source code of this and many other demos for free, with no obligations, for 30 days.

Compatible with:

ReactAngularVueSvelteHTML5Salesforce Lightning

Made with JointJS+

All features required to build this demo are included in the commercial JointJS+ package. Don't have a license yet? Start a trial and build professional applications with ease.

Compatible with:

ReactAngularVueSvelteHTML5Salesforce Lightning

Made with JointJS

The source code of this demo is available in the JointJS open-source library which helps developers create simple visual applications in less time.

Compatible with:

ReactAngularVueSvelteHTML5Salesforce Lightning

Made with JointJS

All features required to build this demo application are included in our open-source library, JointJS. Download the package and create basic visual applications in no time.

Compatible with:

ReactAngularVueSvelteHTML5Salesforce Lightning

Speed up your development with a powerful library