Skip to main content

DefaultObject

<PropTable>: Couldn't find prop definition for `DefaultObjectOptions`
PropertiesConfig
<PropTable>: Couldn't find prop definition for `DefaultObjectPropertiesConfig`
info

The default object will be rendered if no dedicated widget is available. It will try and render any properties available from the server along with their relevant validation.

For example:

rendered from a sample server schema of:

"TestPropertiesSchema": {
"additionalProperties": false,
"cache": true,
"properties": {
"number": {
"format": "integer",
"title": "number",
"type": "number"
},
"option": {
"enum": ["one", "two", "three"],
"enumNames": [],
"title": "option",
"type": "string"
},
"state": {
"enum": ["ON", "OFF", "UNKNOWN", "ERROR"],
"enumNames": [],
"readOnly": true,
"title": "state",
"type": "string"
},
"string": { "title": "string", "type": "string" }
},
"type": "object"
}

The list of displayed properties can be overridden by passing a list of properties:

layout.yml
- id: test_object
properties:
- id: number
- id: option
readonly: true

Properties can be marked as read only using the readonly flag.