BigScreenUI/src/views/Index.vue

61 lines
1.2 KiB
Vue
Raw Normal View History

2023-11-30 13:40:30 +08:00
<template>
<div>
<div
class="pathItem"
v-for="(item, index) in routeList.list"
:key="index"
@click="toPage(item)"
>
{{ item.name }}
</div>
</div>
</template>
<script setup lang="ts">
const router = useRouter()
const routeList = reactive({
list: [
{
name: 'vant-scss演示',
path: 'vantTest'
},
{
name: '时间测试',
path: 'timeTest'
},
{
name: '全局事件 mitt 演示',
path: 'mittTest'
},
{
name: 'pinia演示',
path: 'piniaTest'
},
{
name: '路由演示',
path: 'piniaTest'
}
]
})
/* eslint-disable @typescript-eslint/no-explicit-any */
const toPage = (item: any) => {
router.push({ name: item.path })
}
</script>
<style scoped lang="scss">
// @mixin fontStyle($size,$color,$weight,$lineH,$align) {
// @mixin flexStyle($js,$al,$dir,$wrap){
.pathItem {
@include fontStyle(48px, green, bold, 80px, center);
@include wh(750px, 80px);
margin-bottom: 12px;
}
2023-12-01 15:05:38 +08:00
2023-11-30 13:40:30 +08:00
</style>