instar
instar copied to clipboard
Recursive get-values-in-paths?
Is it possible to search through a tree for a keyword and return the found value?
It seems that:
(get-values-in-paths tree [* :path]) only searches one level down.
Yea, I've been bitten by this too. It's because * only matches one thing, and not zero or more things. I've been thinking that maybe we need another operator like ** for that... or that you can specify a predicate instead of a literal path and then you can do whatever you want in there?
maybe something that mimicates glob? in glob "?" = 1 character
We already have a way to match on parts of keys with regex so I don't see how '?' makes sense.