Getting a node from draggingTool.draggedParts()

ok - back on this as needed to subclass each step of the drag via dragTool.computeMove. Found a solution in this post from Punkie to do with dragging links.

Answer is to use draggedparts.iteratorKeys and not draggedParts.iterator

   var aPart= null, theKey = '';
   var it = this.draggedParts.iteratorKeys ;
   while (it.next()) {
        aPart = it.value;
        theKey = aPart.data.key
   }

Walter - there is no reference to iteratorKeys in the docs except on the Map page. Looking at the description of iterator, iteratorKeys and iteratorValues the latter two would appear to be shortcuts to values or keys of the iterator. I may be misunderstanding a core concept here, but it feels to me like there is a bug in how iterator instances are returned when dealing with the draggedParts map.

See minimal case in codepen for an example. At each computeMove call it tries to log the key of the dragged item via using iterator then iteratorKeys. It illustrates that iterator fails but iteratorKeys works as expected. As you can see from the codepen, the gojs version being used is http://gojs.net/latest/release/go-debug.js,

Finally, I used draggedParts,iterator having followed the pattern shown in the learn.collections docs here, where examples of how to use iterators are provided.