Re-render diagram with new data (Angular)

We just put out a newer release of GitHub - NorthwoodsSoftware/gojs-angular: A set of Angular components to manage GoJS Diagrams, Palettes, and Overviews

I hope that helps you.

Thank you, I am sorry for the late response.
It looks now better, but still, I have problems. I will explain what happens now:

  1. When I am adding/removing a node from the diagram, the diagram re-rendered with no error - the new release fixed that.
  2. When I am changing the location of the node, for the first time, the diagram not re-rendered, and I got this error: Cannot read the property 'data' of null at go-angular.ls:271
    The code line is dc.diagram.model.assignAllDataProperties(node.data, r.currentValue);
    But, In the second attempt at changing location, the diagram is re-rendering with the right location without error. strange.
    I made sure that in the first attempt the data was valid as the second attempt.

Yes, of course, I am binding the location of the node data in the template also.

OK, we’ve added some null checks to the code: GitHub - NorthwoodsSoftware/gojs-angular: A set of Angular components to manage GoJS Diagrams, Palettes, and Overviews

Thank you, now everything works fine without errors.

1 Like

@trump could you send me you repo pls, i’m trying to do something similar, but i’m kind of new with angular, tnks in advance