{"id":13403475,"url":"https://github.com/josdejong/jsoneditor","last_synced_at":"2025-05-12T18:29:53.727Z","repository":{"id":3053507,"uuid":"4075232","full_name":"josdejong/jsoneditor","owner":"josdejong","description":"A web-based tool to view, edit, format, and validate JSON","archived":false,"fork":false,"pushed_at":"2025-03-28T07:58:22.000Z","size":60546,"stargazers_count":11844,"open_issues_count":231,"forks_count":2057,"subscribers_count":226,"default_branch":"develop","last_synced_at":"2025-04-16T00:07:05.688Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"gionkunz/chartist-js","license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/josdejong.png","metadata":{"files":{"readme":"README.md","changelog":"HISTORY.md","contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"josdejong"}},"created_at":"2012-04-19T13:05:41.000Z","updated_at":"2025-04-15T23:45:29.000Z","dependencies_parsed_at":"2023-07-05T19:16:23.054Z","dependency_job_id":"9b3c2313-522e-407b-bc8f-3bcc4d29b2bc","html_url":"https://github.com/josdejong/jsoneditor","commit_stats":{"total_commits":1567,"total_committers":100,"mean_commits":15.67,"dds":0.2035737077217613,"last_synced_commit":"d0df2f4c383d8935df750c760a6e69deefa0ff14"},"previous_names":[],"tags_count":216,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/josdejong%2Fjsoneditor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/josdejong%2Fjsoneditor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/josdejong%2Fjsoneditor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/josdejong%2Fjsoneditor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/josdejong","download_url":"https://codeload.github.com/josdejong/jsoneditor/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250455437,"owners_count":21433512,"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","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":[],"created_at":"2024-07-30T19:01:30.429Z","updated_at":"2025-04-23T14:42:06.816Z","avatar_url":"https://github.com/josdejong.png","language":"JavaScript","readme":"# JSON Editor\n\n[![Version](https://img.shields.io/npm/v/jsoneditor.svg)](https://www.npmjs.com/package/jsoneditor)\n[![Downloads](https://img.shields.io/npm/dm/jsoneditor.svg)](https://www.npmjs.com/package/jsoneditor)\n[![Maintenance](https://img.shields.io/maintenance/yes/2025.svg)](https://github.com/josdejong/jsoneditor/pulse)\n[![License](https://img.shields.io/github/license/josdejong/jsoneditor.svg)](https://github.com/josdejong/jsoneditor/blob/master/LICENSE)\n[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fjosdejong%2Fjsoneditor.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fjosdejong%2Fjsoneditor?ref=badge_shield)\n\nJSON Editor is a web-based tool to view, edit, format, and validate JSON. It has various modes such as a tree editor, a code editor, and a plain text editor. The editor can be used as a component in your own web application. It can be loaded as CommonJS module, AMD module, or as a regular javascript file.\n\nThe library was originally developed as core component of the popular web application https://jsoneditoronline.org and has been open sourced since then.\n\nSupported browsers: Chrome, Firefox, Safari, Edge.\n\n\u003cimg alt=\"json editor\" src=\"https://raw.github.com/josdejong/jsoneditor/master/misc/jsoneditor.png\"\u003e \u0026nbsp; \u003cimg alt=\"code editor\" src=\"https://raw.github.com/josdejong/jsoneditor/master/misc/codeeditor.png\"\u003e\n\nContinuous integration tests are run on [GitHub Actions](https://github.com/josdejong/mathjs/actions), and [LambdaTest](https://www.lambdatest.com) is used to test on all major browsers.\n\n[![LambdaTest](https://raw.github.com/josdejong/mathjs/master/misc/lambdatest.svg)](https://www.lambdatest.com)\n\nThanks, GitHub Actions and LambdaTest for the generous support for this open source project!\n\n## Successor: svelte-jsoneditor\n\nThis library [`jsoneditor`](https://github.com/josdejong/jsoneditor) has a successor: [`svelte-jsoneditor`](https://github.com/josdejong/svelte-jsoneditor). The new editor is not a one-to-one replacement, so there may be reasons to stick with `jsoneditor`. \nThe main differences between the two [are described here](https://github.com/josdejong/svelte-jsoneditor#differences-between-josdejongsvelte-jsoneditor-and-josdejongjsoneditor).\n\n## Features\n\nJSONEditor has various modes, with the following features.\n\n### Tree mode\n\n- Change, add, move, remove, and duplicate fields and values.\n- Sort arrays and objects.\n- Transform JSON using [JMESPath](http://jmespath.org/) queries.\n- Colorized code.\n- Color picker.\n- Search \u0026 highlight text in the tree view.\n- Undo and redo all actions.\n- JSON schema validation (powered by [ajv](https://github.com/epoberezkin/ajv)).\n\n### Code mode\n\n- Colorized code (powered by [Ace](https://ace.c9.io)).\n- Inspect JSON (powered by [Ace](https://ace.c9.io)).\n- Format and compact JSON.\n- Repair JSON.\n- JSON schema validation (powered by [ajv](https://github.com/epoberezkin/ajv)).\n\n### Text mode\n\n- Format and compact JSON.\n- Repair JSON.\n- JSON schema validation (powered by [ajv](https://github.com/epoberezkin/ajv)).\n\n### Preview mode\n\n- Handle large JSON documents up to 500 MiB.\n- Transform JSON using [JMESPath](http://jmespath.org/) queries.\n- Format and compact JSON.\n- Repair JSON.\n- JSON schema validation (powered by [ajv](https://github.com/epoberezkin/ajv)).\n\n## Documentation\n\n- Documentation:\n  - [API](https://github.com/josdejong/jsoneditor/tree/master/docs/api.md)\n  - [Usage](https://github.com/josdejong/jsoneditor/tree/master/docs/usage.md)\n  - [Shortcut keys](https://github.com/josdejong/jsoneditor/tree/master/docs/shortcut_keys.md)\n- [Examples](https://github.com/josdejong/jsoneditor/tree/master/examples)\n- [Source](https://github.com/josdejong/jsoneditor)\n- [History](https://github.com/josdejong/jsoneditor/blob/master/HISTORY.md)\n\n\n## Install\n\nwith npm (recommended):\n\n    npm install jsoneditor\n\nAlternatively, you can use another JavaScript package manager like https://yarnpkg.com/, or a CDN such as https://cdnjs.com/ or https://www.jsdelivr.com/.\n\n## Use\n\n\u003e Note that in the following example, you'll have to change the urls `jsoneditor/dist/jsoneditor.min.js` and `jsoneditor/dist/jsoneditor.min.css` to match the place where you've downloaded the library, or fill in the URL of the CDN you're using.\n\n```html\n\u003c!DOCTYPE HTML\u003e\n\u003chtml lang=\"en\"\u003e\n\u003chead\u003e\n    \u003c!-- when using the mode \"code\", it's important to specify charset utf-8 --\u003e\n    \u003cmeta charset=\"utf-8\"\u003e\n\n    \u003clink href=\"jsoneditor/dist/jsoneditor.min.css\" rel=\"stylesheet\" type=\"text/css\"\u003e\n    \u003cscript src=\"jsoneditor/dist/jsoneditor.min.js\"\u003e\u003c/script\u003e\n\u003c/head\u003e\n\u003cbody\u003e\n    \u003cdiv id=\"jsoneditor\" style=\"width: 400px; height: 400px;\"\u003e\u003c/div\u003e\n\n    \u003cscript\u003e\n        // create the editor\n        const container = document.getElementById(\"jsoneditor\")\n        const options = {}\n        const editor = new JSONEditor(container, options)\n\n        // set json\n        const initialJson = {\n            \"Array\": [1, 2, 3],\n            \"Boolean\": true,\n            \"Null\": null,\n            \"Number\": 123,\n            \"Object\": {\"a\": \"b\", \"c\": \"d\"},\n            \"String\": \"Hello World\"\n        }\n        editor.set(initialJson)\n\n        // get json\n        const updatedJson = editor.get()\n    \u003c/script\u003e\n\u003c/body\u003e\n\u003c/html\u003e\n```\n\n\n## Build\n\nThe code of the JSON Editor is located in the folder `./src`. To build \njsoneditor:\n\n- Install dependencies:\n\n  ```\n  npm install\n  ```\n\n- Build JSON Editor:\n\n  ```\n  npm run build\n  ```\n\n  This will generate the files `./jsoneditor.js`, `./jsoneditor.css`, and  \n  minified versions in the dist of the project.\n\n- To automatically build when a source file has changed:\n\n  ```\n  npm start\n  ```\n\n  This will update `./jsoneditor.js` and `./jsoneditor.css` in the dist folder\n  on every change, but it will **NOT** update the minified versions as that's\n  an expensive operation.\n\n\n## Test\n\nRun unit tests:\n\n```\nnpm test\n```\n\nRun code linting ([JavaScript Standard Style](https://standardjs.com/)):\n\n```\nnpm run lint\n```\n\n\n## Custom builds\n\nThe source code of JSONEditor consists of CommonJS modules. JSONEditor can be bundled in a customized way using a module bundler like [browserify](http://browserify.org/) or [webpack](http://webpack.github.io/). First, install all dependencies of jsoneditor:\n\n    npm install\n\nTo create a custom bundle of the source code using browserify:\n\n    browserify ./index.js -o ./jsoneditor.custom.js -s JSONEditor\n\nThe Ace editor, used in mode `code`, accounts for about one third of the total\nsize of the library. To exclude the Ace editor from the bundle:\n\n    browserify ./index.js -o ./jsoneditor.custom.js -s JSONEditor -x brace -x brace/mode/json -x brace/ext/searchbox\n\nTo minify the generated bundle, use [uglifyjs](https://github.com/mishoo/UglifyJS2):\n\n    uglifyjs ./jsoneditor.custom.js -o ./jsoneditor.custom.min.js -m -c\n\n\n## License\n\n`jsoneditor` is released as open source under the permissive the [Apache 2.0 license](LICENSE.md).\n\n**If you are using jsoneditor commercially, there is a _social_ (but no legal) expectation that you help fund its maintenance. [Start here](https://github.com/sponsors/josdejong).**\n","funding_links":["https://github.com/sponsors/josdejong","https://github.com/sponsors/josdejong)."],"categories":["JavaScript","JSON editor","Editors","others","前端开发框架及项目","Editors [🔝](#readme)","编辑器","open source json editors"],"sub_categories":["Runner","其他_文本生成、文本对话","运行器","运行器e2e测试"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosdejong%2Fjsoneditor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjosdejong%2Fjsoneditor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjosdejong%2Fjsoneditor/lists"}