React json compare view plugin, supports expansion and hiding.use react hooks.
npm install react-json-view-compareReact json compare view plugin, supports expansion and hiding. Uses react hooks.
- https://codesandbox.io/s/jovial-meadow-v17pw

- Github
``js`
npm install --save react-json-view-compare
`jsx
import ReactJsonViewCompare from 'react-json-view-compare';
const oldData = {
name: 'super',
age: 18,
task: [
{ name: 'eat', time: '09:00' },
{ name: 'work', time: '10:00' },
{ name: 'sleep', time: '22:00' }
]
};
const newData = {
name: 'coolapt',
age: 20,
task: [
{ name: 'eat', time: '09:00' },
{ name: 'work', time: '10:00' },
{ name: 'sleep', time: '23:00' },
{ name: 'running', time: '08:00' }
]
};
function App() {
return
}
ReactDOM.render(
``
!示例1
| Attribute | Type | Default |
| --------- | ---- | ------- |
| oldData | any | no |
| newData | any | no |
not yet...
如果喜欢请给个星星,谢谢。
If you like, please give me a star, thank you.
如果需要帮助: QQ:1573815240 邮箱: 1573815240@qq.com
if you need help: QQ:1573815240 email: 1573815240@qq.com