vue-yun-ui
v0.0.1
Published
vue-yun-com 动态加载远端组件
Downloads
3
Readme
vue-yun-com 动态加载远端组件
Attributes
| 参数 | 说明 | 类型 | 可选值 | 默认值 | |------------- |---------------- |---------------- |---------------------- |----------| | _name | 云组件名称 | string | — | — | | _rem | 单位 | string | [true, false] | false[px] |
Installation
npm:
npm i vue-yun-com -S
component register [global or partial]
import YunCom from 'vue-yun-com';
// global register
Vue.component([YunCom.name]: YunCom)
// or partial regisger
export default {
components: {
[YunCom.name]: YunCom
}
}
Usage
<template>
<YunCom v-model="status" _name="VmSwitch"></YunCom>
<YunCom v-model="status" _name="VmSwitch" _rem></YunCom>
</template>
<script>
import YunCom from 'vue-yun-com'
export default {
data () {
return {
status: false
}
},
components: {
YunCom
}
}
</script>