{"id":19580760,"url":"https://github.com/warriorbrian/v-json-edit","last_synced_at":"2025-10-30T09:03:00.162Z","repository":{"id":54177068,"uuid":"278337960","full_name":"warriorBrian/v-json-edit","owner":"warriorBrian","description":"vue json editor","archived":false,"fork":false,"pushed_at":"2021-03-05T05:39:53.000Z","size":10,"stargazers_count":7,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-23T10:06:00.452Z","etag":null,"topics":["javascript","json","jsoneditor","v-json-edit","vue"],"latest_commit_sha":null,"homepage":"","language":"Vue","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/warriorBrian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-09T10:48:18.000Z","updated_at":"2025-06-18T00:59:56.000Z","dependencies_parsed_at":"2022-08-13T08:20:58.069Z","dependency_job_id":null,"html_url":"https://github.com/warriorBrian/v-json-edit","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/warriorBrian/v-json-edit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/warriorBrian%2Fv-json-edit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/warriorBrian%2Fv-json-edit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/warriorBrian%2Fv-json-edit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/warriorBrian%2Fv-json-edit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/warriorBrian","download_url":"https://codeload.github.com/warriorBrian/v-json-edit/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/warriorBrian%2Fv-json-edit/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268512159,"owners_count":24261887,"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-08-03T02:00:12.545Z","response_time":2577,"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":["javascript","json","jsoneditor","v-json-edit","vue"],"created_at":"2024-11-11T07:29:30.313Z","updated_at":"2025-10-30T09:03:00.106Z","avatar_url":"https://github.com/warriorBrian.png","language":"Vue","readme":"## v-json-edit\n\n### Install\n\n```bash\n$ npm install --save v-json-edit\n# or\n$ yarn add v-json-edit\n```\n\n### Usage\n\n```js\nimport Vue from 'vue'\nimport vJsonEdit from 'v-json-edit'\nVue.use(vJsonEdit)\n```\n\n```html\n\u003c!--开启编辑，拖拽，监听改变, 将on-change修改为change防止与系统冲突--\u003e\n\u003cv-json-edit v-model=\"json\" edit drag @change=\"changeHandle\"\u003e\u003c/v-json-edit\u003e\n```\n\n```js\nexport default {\n  data () {\n    return {\n       json: {} // 渲染值\n    }\n  },\n  methods: {\n    changeHandle (val) {\n      // 改变值\n    }\n  }\n}\n```\n\n### API\n\n#### Attributes\n\n参数 | 说明 | 类型 |  默认值 | 可选值\n---|---|---|---|---\nv-model | 渲染值 | String/Object/Array/Number | - | -\nmode | 默认编辑器模式 | string | tree | -\nmodes | 编辑器模式 | array | [\"tree\", \"code\", \"form\", \"text\", \"view\", \"preview\"] | -\nsearch | 右侧是否展示搜索 | boolean | false | -\nlang | 显示语言 | string | en | en, pt-BR, zh-CN, tr, ja, fr-FR\ndrag | 是否可拖拽 | boolean | false | -\nedit | 是否可编辑 | boolean | false | -\nexpand | 展开所有数据 | boolean | true | -\nhistory | 启用历史记录操作按钮 | boolean | true | -\nmainMenuBar | 是否显示主功能栏 | boolean | true | -\nnavigationBar | 显示树结构上当前位置,适用于: tree/form/view模式 | boolean | false | -\n\n#### Events\n\n事件名称 | 说明 | 回调参数\n---|---|---\nchange | 当值进行改变时触发 | value\non-mode | 当模式切换时触发 | {newMode, oldMode}\non-error | 错误时触发 | error\non-select-text | 当选中数据时触发(仅适用于mode: `code`, 'text') | {start, end, text}\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwarriorbrian%2Fv-json-edit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwarriorbrian%2Fv-json-edit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwarriorbrian%2Fv-json-edit/lists"}