rahal
June 10, 2022, 8:48am
1
I am trying add blinking behaviour to links in FixedForceDirectedLayout graph. I have followed below example and was success for Nodes.
Following is the code segment for blink Nodes
Now I want to apply same logic for links. But I can not access linkDataArray as in example (arr = m.linkDataArray) as it throws ‘linkDataArray’ does not exist in type ‘Model’.
Thank you!
walter
June 10, 2022, 11:47am
2
Construct a GraphLinksModel , not a Model .
rahal
June 10, 2022, 12:35pm
3
walter:
GraphLinksModel
I tried as follows and it worked!
var arr = (m as go.GraphLinksModel).linkDataArray;
walter
June 10, 2022, 12:49pm
4
Please be careful in your terminology.
A compiler never “throws” an exception. That’s just a compilation error message.
At run-time the code may “throw” an exception. That’s the behavior of the library.
I thought you were talking about a run-time exception, not a TypeScript compiler error message.