Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用 react json 模式表单来创建表单。我正在尝试提交表格。当我发送空值时。密钥从数据中消除。例如在一个表单中,我有两个字段名称和地址。输入名称="abc" 地址=""
输出{名称:abc}
所需的输出{名称:abc,地址:}
您可以使用默认值。尝试
{ "title": "A registration form", "description": "A simple form example.", "type": "object", "properties": { "name": { "type": "string", "title": "name", "default": "" }, "address": { "type": "string", "title": "address", "default": "" } } }