Quantcast
Channel: GoJS - Northwoods Software
Viewing all articles
Browse latest Browse all 7069

Does the Radial Layout Template need to be Initialized everytime for Dynamic Data?

$
0
0

@shantanoo-desai wrote:

Hello again,

So I have a much better understanding of using GoJS Radial Template with Angular 2 (Typescript) as I already have a Repository for Reference displaying the same example.

Currently the rendering happens with ngAfterViewInit() which might be good for static applications where the diagram does not use Input from, say, Backend Server. However, I need some help in getting the layout to render with ngOnChanges(). I currently have a none committed code where the the layout gets rendered after some API calls.

Problem

The first time the app fires, and user searches a keyword and gets data from the API and after a few clicks the diagram gets displayed. However, when the user searches something new and the values get passed to the Angular Component there is a zone.js error which I cannot understand at all.

Does one have to call the init() function in the source code everytime the image needs to be rendered? I understand that the generateGraph() is called within the init() function, but is there a way to just initialize the diagram first and then generate the Graph?

usually if I do call the init() without the generateGraph() it will show vertex error.

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 7069

Trending Articles