jsonform
Version:
Client-side JavaScript library that generates HTML forms from structured data models expressed using a JSON schema, possibly completed by a form layout description.
41 lines • 731 B
JSON
{
"schema": {
"friends": {
"type": "array",
"items": {
"type": "object",
"title": "Friend",
"properties": {
"nick": {
"type": "string",
"title": "Nickname"
},
"animals": {
"type": "array",
"items": {
"type": "string",
"title": "Animal name"
}
}
}
}
}
},
"form": [
{
"type": "array",
"items": {
"type": "section",
"items": [
"friends[].nick",
{
"type": "array",
"items": [
"friends[].animals[]"
]
}
]
}
}
]
}