大屏可视化组件套装(DataV 支持vue 3,vite)
DataV(vue3+ vite)
1.开源连接地址 GitHub - vaemusic/datav-vue3: datav Vue3+TS+Vite版
2,安装
npm install @kjgl77/datav-vue3
3.全局引入
import { createApp } from 'vue'
import App from './App.vue'
import DataVVue3 from '@kjgl77/datav-vue3' const app = createApp(App) app.use(DataVVue3)
4.具体使用
<template>
<div>
<dv-digital-flop :config="config1" style="margin-left:-60px;margin-bottom:-20px">
</dv-digital-flop>
</div>
</template>
<script>
export default {
components: {},
data() {
return {
data: [],
curCarSatic: {},
parkCode: "",
config1: { number: [0], toFixed: 0, content: "{nt}" },
}
},
mounted() {
this.parkingSpaceStatic()
},
methods: {
parkingSpaceStatic(){
this.config1 = {
number: [1000],
toFixed: 0,
content: "{nt}",
style: {
fontSize: 32,
fill: '#ffff8d',
fontWeight: '400',
textAlign : 'start',
shadowColor:'#333',
fontFamily:'Impact'}
},
},
};
</script>
<style scoped>
</style>
5.使用方法 介绍 | DataV
6.数字翻牌器注意:config的初始值为0 才会有滚动的效果
更多推荐
所有评论(0)