Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/marianoguerra/jsonpath.js
modern and tested jsonpath implementation
https://github.com/marianoguerra/jsonpath.js
Last synced: about 1 month ago
JSON representation
modern and tested jsonpath implementation
- Host: GitHub
- URL: https://github.com/marianoguerra/jsonpath.js
- Owner: marianoguerra
- Created: 2012-10-15T09:31:37.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2012-11-08T13:03:04.000Z (about 12 years ago)
- Last Synced: 2023-04-21T08:16:32.063Z (over 1 year ago)
- Language: JavaScript
- Homepage: https://marianoguerra.github.com/jsonpath.js/test/
- Size: 133 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rest
Awesome Lists containing this project
README
jsonpath.js
===========a modern and tested js implementation of jsonpath (http://goessner.net/articles/JsonPath/)
status
------for now the only supported parts are:
* selecting from the root (expressions that start with $.)
* attribute traversing using the dot syntax ($.a.b, not a['b'])
* wildcard ($.a.*.b)this is because those are the main things I need right now, others will be
added when I need them or I have more time (or you fork and contribute :)things to implement in (my) order of importance
-----------------------------------------------* array selector with [] ($.a[2].b)
* attribute selector with [] ($['a']['b'])
* array slice operator ($.a[1:7:-1])
* basic filters ($.store.book[?(@.price < 10)])
* recursive descent ($..book)things I won't implement
-----------------------* arbitrary script expression
TODO
----* migrate jsonpath parsing to jison?
* have the tests in a json file to be shared with other jsonpath implementationsauthor
------marianoguerra
license
-------MIT