We borrowed the arrange and align function from good old PowerPoint. So if you've been racking your brain on how to allow users to select and align objects, you don't have to. Check out the demo below to see how to do it.
Click the alignment icon to open the context menu and change the alignment to see the behavior of the selected elements.
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.