{"id":22064758,"url":"https://github.com/ldarren/jwalk","last_synced_at":"2025-10-13T03:45:11.769Z","repository":{"id":143155890,"uuid":"106116890","full_name":"ldarren/jwalk","owner":"ldarren","description":"JSON editor with JWalk/JSONPath","archived":false,"fork":false,"pushed_at":"2017-11-10T01:12:45.000Z","size":1842,"stargazers_count":3,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-13T01:15:57.844Z","etag":null,"topics":["json-path"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ldarren.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-10-07T17:27:52.000Z","updated_at":"2019-07-15T18:09:38.000Z","dependencies_parsed_at":"2023-04-03T21:47:15.367Z","dependency_job_id":null,"html_url":"https://github.com/ldarren/jwalk","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ldarren/jwalk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ldarren%2Fjwalk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ldarren%2Fjwalk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ldarren%2Fjwalk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ldarren%2Fjwalk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ldarren","download_url":"https://codeload.github.com/ldarren/jwalk/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ldarren%2Fjwalk/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279013522,"owners_count":26085368,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-13T02:00:06.723Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["json-path"],"created_at":"2024-11-30T19:13:27.813Z","updated_at":"2025-10-13T03:45:11.765Z","avatar_url":"https://github.com/ldarren.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# JSon\n\nJSon is an online JSON viewer that supported jwalk/jsonpath, json pretify and json stringify.\nJSon is heavily based on the [Editor](https://markhillard.github.io/Editor/)\n\n- [jQuery](http://jquery.com/)\n- [jQuery UI - Resizable](https://jqueryui.com/resizable/)\n- [CodeMirror](https://codemirror.net/)\n- [FileSaver.js](https://github.com/eligrey/FileSaver.js)\n- [pico-common](https://github.com/ldarren/pico-common/bin/pico.js) provides acutal jWalk implementation\n\n## Features\n\n- json parse\n- json stringify\n- jwalk/jsonpath\n- Auto-Save (Local Storage)\n- Resizable Code/Preview Pane\n- Preview Pane Width Indicator\n- Syntax Highlighting\n- Code Folding\n- Tag/Bracket Matching\n- Auto-Close HTML Tags\n- Text Wrapping Toggles\n- Clear Editor\n- Save As JSON File\n- Dependency Injection\n\n### CodeMirror Addons\n\n- [Sublime Keymap](https://codemirror.net/demo/sublime.html)\n- [VIM Keymap](https://codemirror.net/demo/vim.html)\n\n**Note:** If VIM is enabled the Sublime Keymap will be disabled, and vice-versa.\n\n## Browser Support\n\nJSon works in all modern web browsers and IE10+.\n\n## JWalk\n\nThe JWalk tool uses in this editor is derived from [Stefan Goessner's JSON Path](http://goessner.net/articles/JsonPath/). JWalk uses valid javascript syntax instead of dot-notation or bracket notation\n\n### JWalk VS JSONPath\n\nHere is a complete overview and a side by side comparison of the JWalk syntax elements with its JSONPath counterparts.\n\n| JSONPath | JWalk | Description |\n| ------------- | ------------- | ------------- |\n| $ | $ | the root object/element |\n| @ | function paramter | the current object/element, Jwalk supported standard javascript function, current object is the first pass-in parameter |\n| . or [] | () | child operator, JWalk uses chained function |\n| .. | ('..', 'key') | recursive descent. JSONPath borrows this syntax from E4X. |\n| * | * | wildcard. All objects/elements regardless their names. |\n| [] | () | subscript operator. XPath uses it to iterate over element collections and for predicates. In Javascript and JSON it is the native array operator. |\n| [,] | (,) | Union operator in XPath results in a combination of node sets. JSONPath allows alternate names or array indices as a set. |\n| [start:end:step] | ([start, end, step]) | array slice operator borrowed from ES4. |\n| ?() | ( curr =\u003e {} ) | applies a filter (script) expression. |\n| () | ( curr =\u003e {} ) | script expression, using the underlying script engine, JWalk has same syntax for filter and script expression |\n\n### Jwalk Examples\n\nLet's practice JWalk expressions by some more examples. We start with a simple JSON structure built after Stefen's example representing a bookstore\n\n```json\n{ \"store\": {\n    \"book\": [ \n      { \"category\": \"reference\",\n        \"author\": \"Nigel Rees\",\n        \"title\": \"Sayings of the Century\",\n        \"price\": 8.95\n      },\n      { \"category\": \"fiction\",\n        \"author\": \"Evelyn Waugh\",\n        \"title\": \"Sword of Honour\",\n        \"price\": 12.99\n      },\n      { \"category\": \"fiction\",\n        \"author\": \"Herman Melville\",\n        \"title\": \"Moby Dick\",\n        \"isbn\": \"0-553-21311-3\",\n        \"price\": 8.99\n      },\n      { \"category\": \"fiction\",\n        \"author\": \"J. R. R. Tolkien\",\n        \"title\": \"The Lord of the Rings\",\n        \"isbn\": \"0-395-19395-8\",\n        \"price\": 22.99\n      }\n    ],\n    \"bicycle\": {\n      \"color\": \"red\",\n      \"price\": 19.95\n    }\n  }\n}\n```\n| JSOPNPath | JWalk | Result |\n| ------------- | ------------- | ------------- |\n| $.store.book[*].author | $('store')('book')('*')('author') | the authors of all books in the store |\n| $..author | $('..', 'author') | all authors |\n| $.store.* | $('store')('*') | all things in store, which are some books and a red bicycle. |\n| $.store..price | $('store')('..', 'price') | the price of everything in the store. |\n| $..book[2] | $('..', 'book')([2]) | the third book |\n| $..book[-1:] | $('..', 'book')( [-1] ) | the last book in order. |\n| $..book[0,1] | $('..', 'book')([0, 1]) | the first two books |\n| $..book[:2] | $('..', 'book')(0, 2) | the first two books |\n| $..book[?(@.isbn)] | $('..', 'book')( curr =\u003e curr.isbn ? curr : void 0 ) | filter all books with isbn number |\n| $..book[?(@.price\u003c10)] | $('..', 'book')( curr =\u003e curr.price \u003c 10 ? curr : void 0 ) | filter all books cheapier than 10 |\n| N.A | $('..', 'book')( curr =\u003e curr.price * 3 ) | map all book prices multiple by 3 |\n| $..* | $('..', '*') | all Elements in XML document. All members of JSON structure. |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fldarren%2Fjwalk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fldarren%2Fjwalk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fldarren%2Fjwalk/lists"}