3 ms·
Except that XPath and JSONPath are overpowered. I'd welcome a simple standard path syntax for JSON, for instance, I'd want to use for reporting schema errors in
by exyi 2y ago
Except that XPath and JSONPath are overpowered. I'd welcome a simple standard path syntax for JSON, for instance, I'd want to use for reporting schema errors in JSON document ($.users[10].name must be a string). I can use JSONPath, sure, but even this subset is annoying to parse - compared to a filepath which you can parse with `path.split('/')`.
- HarHarVeryFunny 2y agoAgreed - for a lot of use cases all you need is a pathname-like way to refer to elements in the DOM, not a search/filtering mechanism.
- hgyjnbdet 2y agoYou might like gron then. https://github.com/tomnomnom/gron https://github.com/tomnomnom/gron For 90% on my needs this is all I need.