refactor: V3 版本重构已基本完成

This commit is contained in:
RockYang
2023-06-15 09:41:30 +08:00
parent be6e8c7713
commit 567cdc6f8d
99 changed files with 5209 additions and 5752 deletions

View File

@@ -2,25 +2,20 @@
<div>{{ title }}</div>
</template>
<script>
import { defineComponent } from "vue"
<script setup>
import {onMounted, ref} from "vue"
import {isMobile} from "@/utils/libs";
import {useRouter} from "vue-router"; // 导入useRouter函数
export default defineComponent({
name: 'HomePage',
data () {
return {
title: "Loading page...",
}
},
mounted() {
if (isMobile()) {
this.$router.push("mobile");
} else {
this.$router.push("plus");
}
const title = ref("Loading page...");
const router = useRouter();
onMounted(() => {
if (isMobile()) {
router.push("mobile");
} else {
router.push("chat");
}
})
</script>