SOURCE

console 命令行工具 X clear

                    
>
console
new Vue({
  el: "#app",
  data: {
		options: {
			formItem: [
        {
          type: 'radio',
          text: 'Radio',
          props: {
						value: true
          },
          label: '单选框'
        },
        {
        	type: 'radioGroup',
        	label: '水果',
        	// 子项可以省略type: 'radio'
        	// 并且提供了简写方式 可以直接写props的属性 而不用像下面这样使用
        	// props: {
        	//		disabled: true,
        	//		label: '香蕉'
        	// }
        	children: [
        		{
							disabled: true,
        			label: '香蕉'
        		},
        		{
        			label: '苹果',
        		},
        		{
        			label: '西瓜',
        		}
      		]
        },
    		{
        	type: 'radioGroup',
        	label: '水果',
    			props: {
    				type: 'button'
  				},
        	children: [
        		{
        			label: '香蕉',
              disabled: true
        		},
        		{
        			label: '苹果',
        		},
        		{
        			label: '西瓜',
        		}
      		]
        },
      ]
    }
  }
})
<link rel="stylesheet" href="//unpkg.com/view-design/dist/styles/iview.css">
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.min.js"></script>
<script src="//unpkg.com/view-design/dist/iview.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/vue-form-maker/dist/vue-form-maker.js"></script>
<div id="app">
  <vue-form-maker :options="options" />
</div>
#app {
  padding: 10px 20px;
}