1.0.0 • Published 2 years ago

json-schema-editor-lite v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

Json Schema 可视化编辑器(Antd)

基于 json-schema-editor-visualjson-schema-editor-antd 改造,支持元组(tuple)功能

快速开始

# 开发
npm run dev

# 构建
npm run build

# 发布前预览
npm run prepublishOnly && arco preview

# 发布至物料平台(需先发布 NPM 包)
arco sync

示例

npm install json-schema-editor-lite
import JsonSchemaEditor from 'json-schema-editor-lite';
import 'json-schema-editor-lite/dist/css/index.css';
import { useEffect } from 'react';

export default () => {

  const [jsonData, setJsonData] = useEffect({});

  return (
    <JsonSchemaEditor
      data={jsonData}
      onChange={(data) => {
        setJsonData(data);
      }}
    />
  )
}

示例

感谢