Skip to content

Commit 3efbae5

Browse files
committed
feat(node): allow to cast as String
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
1 parent 4157bc6 commit 3efbae5

2 files changed

Lines changed: 48 additions & 267 deletions

File tree

lib/node/node.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,14 @@ export abstract class Node {
436436
return JSON.stringify([structuredClone(this._data), this._knownDavService.toString()])
437437
}
438438

439+
/**
440+
* String representation of the node
441+
*/
442+
toString(): string {
443+
const constructorData: NodeConstructorData = [this._data, this._knownDavService]
444+
return JSON.stringify(constructorData)
445+
}
446+
439447
}
440448

441449
/**

0 commit comments

Comments
 (0)