feat(router): provide meaningful toString impls
This commit is contained in:
@ -70,4 +70,8 @@ function contains<T>(tree: TreeNode<T>, subtree: TreeNode<T>): boolean {
|
||||
|
||||
export class TreeNode<T> {
|
||||
constructor(public value: T, public children: TreeNode<T>[]) {}
|
||||
|
||||
toString(): string {
|
||||
return `TreeNode(${this.value})`;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user