#Association Methods

Programatically control associations with the below methods.

#relationships.addAssociation

Set an image to the background of the node
arguments
node.relationships.addAssociation({ child: otherNode, lineColor: '#000', lineOpacity: 1, lineEffect: 'outline', lineWidth: 10, isStraightLine: false, showParentArrow: true, showChildArrow: false });
NameTypeDescription
childobjectThe child node to connect to
lineColorstringThe hex color of the connecting line
lineOpacityintegerThe opacity percentage of the connecting line (0.0 - 1.0)
lineEffectstringThe line effect to apply (postItNote, dropShadow, outlined, tattered, posterize, pencil)
lineWidthintegerThe width in px of the connecting line
isStraightLinebooleanSet to true to make the line straight, defaults to bezier curve
showParentArrowbooleanShow the arrowhead on the parent side
showChildArrowbooleanShow the arrowhead on the child side
returns

null