-
Notifications
You must be signed in to change notification settings - Fork 3
/
app.vue
64 lines (60 loc) · 1.27 KB
/
app.vue
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<script setup lang="ts">
import { Buffer } from 'buffer/';
window.Buffer = Buffer;
const route = useRoute();
const app = useAppConfig();
useHead({
title: () => route.meta?.title ?? '',
titleTemplate: (titleChunk) =>
titleChunk
? `${titleChunk} - ${app.meta.title}`
: `${app.meta.title}${app.meta.titleSuffix ? ` | ${app.meta.titleSuffix}` : ''}`,
htmlAttrs: {
lang: 'en',
dir: 'ltr',
},
link: [
{
rel: 'icon',
type: 'image/png',
href: '/img/favicon.png',
},
],
meta: [
{
name: 'description',
content: () => route.meta.description ?? app.meta.description,
},
{
name: 'twitter:card',
content: 'summary_large_image',
},
...(app.meta.twitter?.site ? [{ name: 'twitter:site', content: app.meta.twitter.site }] : []),
{
name: 'og:image:type',
content: 'image/png',
},
{
name: 'og:image:width',
content: '1200',
},
{
name: 'og:image:height',
content: '630',
},
{
name: 'og:image',
content: '/img/preview.png',
},
],
});
</script>
<template>
<div>
<NetworkSwitcher />
<NuxtLayout>
<NuxtLoadingIndicator color="rgb(var(--color-primary-500))" />
<NuxtPage />
</NuxtLayout>
</div>
</template>