Error converting treemapper to angular

i m trying to convert tree mapper to angular i came across a problem that in angular
i get an error on treenode which is a function that returns nothing
same error is on mapping link in link templates
my question is how to call this treenode() in this template in agular


You need to define TreeNode as a class that extends go.Node.

There are a lot of examples of translating classes from JavaScript to TypeScript in the extensionsTS folder.