@mistio/mist-form
Version:
A Webcomponent that renders a form defined by a JSONSchema & an optional UISchema spec
62 lines • 1.45 kB
JSON
{
"jsonSchema": {
"type": "object",
"properties": {
"age": {
"type": "integer",
"title": "Age"
},
"items": {
"type": "array",
"items": {
"type": "object",
"anyOf": [
{
"properties": {
"foo": {
"type": "string"
}
}
},
{
"properties": {
"bar": {
"type": "string"
}
}
}
]
}
}
},
"anyOf": [
{
"title": "First method of identification",
"properties": {
"firstName": {
"type": "string",
"title": "First name",
"default": "Chuck"
},
"lastName": {
"type": "string",
"title": "Last name"
}
}
},
{
"title": "Second method of identification",
"properties": {
"idCode": {
"type": "string",
"title": "ID code"
}
}
}
]
},
"uiSchema": {},
"formData": {
"firstName": "Chuck"
}
}