skutil-datamodel
v1.0.6
Published
datamodel of skutil used by the author privately.
Downloads
8
Readme
A datamodel util for backend in the skutil system used by the author privately.
Install
安装
yarn add skutil-datamodel
Usage
const { ModelSchema } = require('skutil-datamodel')
const schema = new ModelSchema([
{
'name': 'someObj',
'label': '',
'type': 'object',
'typeInfo': {},
'desc': '',
'required': true,
'id': 'r8r6ac4gdkg0'
},
{
'parentId': 'r8r6ac4gdkg0',
'name': 'aString',
'label': '',
'type': 'string',
'typeInfo': {},
'defV': '',
'desc': '',
'required': false,
'id': '11utlqk9jqig0'
},
{
'name': 'c',
'label': '',
'type': 'array',
'typeInfo': {},
'desc': '',
'required': true,
'id': '13fma5urtn1g0'
}
])
const displayList = schema.getDisplayList()
const value = displayList.retrieveValue()