0.0.16 • Published 5 months ago

@vjsf-element-ui/theme v0.0.16

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
5 months ago

@lljj/vue-json-schema-form

基于 Element Ui 、Vue2、 JSON Schema 生成表单

通过 @lljj/vue2-form-core 适配 ElementUi 库

安装

## npm
npm install --save @lljj/vue-json-schema-form

## yarn
yarn add @lljj/vue-json-schema-form

使用

<VueForm
    v-model="formData"
    :schema="schema"
>
</VueForm>
//  使用
import VueForm from '@lljj/vue-json-schema-form';

export default {
    name: 'Demo',
    components: {
        VueForm
    },
    data() {
        return {
            formData: {},
            schema: {
                type: 'object',
                required: [
                    'userName',
                    'age',
                ],
                properties: {
                    userName: {
                        type: 'string',
                        title: '用户名',
                        default: 'Liu.Jun',
                    },
                    age: {
                        type: 'number',
                        title: '年龄'
                    },
                    bio: {
                        type: 'string',
                        title: '签名',
                        minLength: 10,
                        default: '知道的越多、就知道的越少',
                        'ui:options': {
                            placeholder: '请输入你的签名',
                            type: 'textarea',
                            rows: 1
                        }
                    }
                }
            }
        };
    }
};

License

Apache-2.0

0.0.16

5 months ago

0.0.15

5 months ago

0.0.14

5 months ago

0.0.13

6 months ago

0.0.12

6 months ago

0.0.11

6 months ago

0.0.10

6 months ago

0.0.9

6 months ago

0.0.8

6 months ago

0.0.7

6 months ago

0.0.6

6 months ago

0.0.5

6 months ago

0.0.4

6 months ago

0.0.3

6 months ago

0.0.2

6 months ago

0.0.1

6 months ago