A solution for editing and publish dynamic web forms with visual editor, providing react components for rendering web forms from JSON schema using ant-design or ant-design-mobile, an visual editor component to edit dynamic form json schema and an server library helping you build an dynamic form system.
This repository is a monorepo that we manage using Lerna. That means that we actually publish several packages to npm from the same codebase, including:
scalable-form-platform
基于动态表单协议(JSON Schema)的表单解决方案,提供了基于 ant-design 和 ant-design-mobile 的前端表单渲染引擎sdk、可视化表单编辑器和可独立部署镜像。
A solution for editing and publish dynamic web forms with visual editor, providing react components for rendering web forms from JSON schema using ant-design or ant-design-mobile, an visual editor component to edit dynamic form json schema and an server library helping you build an dynamic form system.
查看文档 https://scalable-form-platform.github.io/#/
✨ 特性/features
📦 包管理/Packages
我们使用Lerna来进行包管理,所以本仓库会发布多个包到npm,包括:
This repository is a monorepo that we manage using Lerna. That means that we actually publish several packages to npm from the same codebase, including:
⛳️ 快速上手
我们从一个例子快速开始,在这个例子中,我们会渲染一个表单,表单支持用户填写自己的名字(name字段)。
使用scalable-form-antd渲染表单
使用scalable-form-antd,我们需要针对表单需求写一下表单描述(schema),并且将schema作为scalable-form-antd的props传入。
您可以在 codesandbox 查看这个例子的演示。
您可以访问访问scalable-form-antd文档了解更多信息
使用scalable-form-editor可视化编排表单
scalable-form-editor是可视化编排表单的前端组件,您可以通过scalable-form-editor快速搭建您的表单。
您可以在 codesandbox 查看scalable-form-editor的演示,访问这里查看scalable-form-editor的更多文档
使用Scalable Form站点
实际业务使用中,Scalable Form整体上由三个主要部分组成,表单渲染端,表单配置端,表单存储的服务端。
通过docker镜像的方式,你可以很方便地在本地或者服务器部署一个Scalable Form服务器。 你可以从docker hub搜索到Scalable Form服务器的docker镜像 如果你在本地测试,你可以执行以下命令通过
scalable-form-platform镜像开启一个Scalable Form服务器,端口绑定3000开启后,访问
http://localhost:3000/xform/admin即可使用Scalable Form独立站点🖥 浏览器支持/Environment Support
IE / Edge
Firefox
Chrome
Safari
Opera