I use following to detect if a link has changed:
graph.on(\'change:source change:target\', function(link) { if (link.get(\'source\').id && link.ge