app.vue
931 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<script setup lang="ts">
import { isMobile } from "~/utils";
import MobileHeader from "~/components/MobileHeader.vue";
import { useCategoryStore } from "~/stores/category";
// import { useI18n } from 'vue-i18n'
// const { t } = useI18n()
useHead({
link: [{ rel: "icon", type: "image/x-icon", href: "/fav.ico" }],
script: [
{
src: "https://www.googletagmanager.com/gtag/js?id=AW-881504701",
async: true,
},
{
children: `
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'AW-881504701');
`,
type: "text/javascript",
},
],
});
const categoryStore = useCategoryStore();
categoryStore.getList();
</script>
<template>
<Header v-if="!isMobile()" />
<MobileHeader v-if="isMobile()" />
<div class="tw-min-h-[700px]">
<NuxtPage />
</div>
<Footer />
</template>