Open chrisjameslennon opened 4 months ago
Separate from the technical implementation - which i suspect would be tricky - what's the use case?
I am writing a json model generation (with schema validation) library
can you elaborate? when you're traversing down, you can easily keep references to the parents; when is it necessary to not do that such that you'd need the path?
I thought you might ask me that :-) I make several traversals, and gather data on the object. However keeping references to parents may be sufficient. I'll pursue that approach
Sometimes it is helpful to go up the tree as well as down it. Would you consider a method like .upstreamPath() that returns the path, upwards until the root node
To be honest I am not sure it is as simple as that :-) But this feature would be useful I think