Format2Json2View is a React component for displaying JSON objects.Supports automatically formatting json format strings into json.
Install this component with NPM.
npm i format2json2view
Or add to your package.json config file:
"dependencies": {
"format2json2view": "latest"
}
// import the Format2Json2View component
import Format2Json2View from 'Format2Json2View'
const json = {a:1,b:true,c:'c'}
// use the component in your app!
<Format2Json2View source={json}/>
// import the Format2Json2View component
import ReactJson from 'Format2Json2View'
const jsonStr = `{"a":1,"b":true,"d":null,"e":true,"f":false,"g":[1,"2",true,false,null,null]}`
// use the component in your app!
<Format2Json2View data={json}/>
Name | Type | Description |
---|---|---|
source |
json object |
Supports formatting json format strings |
- refactor packaging process