Installations
npm install react-json-edit-criss
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
6.10.3
NPM Version
3.10.10
Score
69.4
Supply Chain
93.7
Quality
74.8
Maintenance
50
Vulnerability
100
License
Releases
Unable to fetch releases
Contributors
Unable to fetch Contributors
Languages
JavaScript (98.18%)
CSS (1.56%)
HTML (0.26%)
Love this project? Help keep it running — sponsor us today! 🚀
Developer
Eightyplus
Download Statistics
Total Downloads
836
Last Day
1
Last Week
1
Last Month
17
Last Year
68
GitHub Statistics
MIT License
11 Stars
139 Commits
5 Forks
2 Watchers
8 Branches
2 Contributors
Updated on Aug 20, 2023
Bundle Size
31.77 kB
Minified
7.84 kB
Minified + Gzipped
Package Meta Information
Latest Version
0.3.2
Package Id
react-json-edit-criss@0.3.2
Size
12.03 kB
NPM Version
3.10.10
Node Version
6.10.3
Total Downloads
Cumulative downloads
Total Downloads
836
Last Day
0%
1
Compared to previous day
Last Week
-88.9%
1
Compared to previous week
Last Month
183.3%
17
Compared to previous month
Last Year
-15%
68
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
react-json-editor
JSON editor for React
Install
How to use
- import JsonEditor component
import { JsonEditor } from 'react-json-edit';
- Add to render method and supply a callback method
1class MyComponent extends Component { 2 3 constructor(props) { 4 super(props); 5 this.state = { 6 json: undefined /* setup here or load elsewhere */ 7 } 8 } 9 10 callback = (changes) => { 11 this.setState({json: changes}); 12 }; 13 14 render() { 15 return ( 16 <div> 17 <JsonEditor value={this.state.json} propagateChanges={this.callback}/> 18 </div> 19 ); 20 } 21}
Parse
It possible to parse and see errorMessage from parsing with the following helper method
1import { parse } from 'react-json-edit'; 2 3load_callback(text) { 4 const parsed = parse(text); 5 6 if(parsed.json === undefined) { 7 this.setState({message: parsed.errorText}); 8 } else { 9 this.setState({json: parsed.json, message: undefined}); 10 } 11} 12 13render() { 14 return ( 15 <div> 16 <JsonEditor value={this.state.json} propagateChanges={this.callback}/> 17 <span>{this.state.message}</span> 18 </div> 19 ); 20}
Styling
I decided to use inline styling, due to troubles with Isomorphic rendering. The styling can be changed with a props on JsonEditor or via css.
<JsonEditor styling={ ... object }
where the following keys can be set: root, array, object, object-row, array-row, value, key, string, number, undefined, boolean, null, button, add-group (AddButton), add-input, add-button, save-button, cancel-button, delete-button
.
Remember that React uses different style names than css does.
or the css class names (which trumps inline style!):
JsonEditor, ArrayItem, ObjectItem, ArrayRow, ObjectRow, KeyItem, StringItem, NumberItem, BooleanItem,
Editor elements:
AddButton, AddInput, add-input, add-button, save-button, cancel-button, delete-button,
Table like style
Add props tableLike={true}
to view json in a table.
1 render() { 2 return ( 3 <div> 4 <JsonEditor value={this.state.json} tableLike={true} propagateChanges={this.callback}/> 5 </div> 6 ); 7 }
TODO
- Test!
- More setup options
- Number of levels
- Configure add buttons
- Schema for adding stuff
- Eventually built in text editor where result is parsed automatically

No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
SAST tool detected but not run on all commits
Details
- Info: SAST configuration detected: CodeQL
- Warn: 0 commits out of 30 are checked with a SAST tool
Reason
dependency not pinned by hash detected -- score normalized to 1
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/codeql-analysis.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/codeql-analysis.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:38: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/codeql-analysis.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:52: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/codeql-analysis.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/node.js.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/node.js.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/node.js.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/Eightyplus/react-json-editor/node.js.yml/master?enable=pin
- Info: 0 out of 6 GitHub-owned GitHubAction dependencies pinned
- Info: 1 out of 1 npmCommand dependencies pinned
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/codeql-analysis.yml:1
- Warn: no topLevel permission defined: .github/workflows/node.js.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Reason
19 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92
- Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx
- Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc
- Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp
- Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27
- Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55
- Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j
- Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg
- Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p
- Warn: Project is vulnerable to: GHSA-4vvj-4cpr-p986
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
Score
3.3
/10
Last Scanned on 2025-02-10
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More