-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathapp.vue
95 lines (92 loc) · 2.9 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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
<template>
<TooltipProvider :delay-duration="0">
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
</TooltipProvider>
</template>
<script setup lang="ts">
const runtimeConfig = useRuntimeConfig();
const route = useRoute();
const { t } = useI18n();
// TODO: Consider using useSeoMeta
// useSeoMeta(() => {
// return {
// titleTemplate: (titleChunk) => {
// // If undefined or blank then we don't need the hyphen
// return titleChunk ? `${titleChunk} - ${t('title')}` : t('title').toString();
// },
// };
// });
useHead(() => {
return {
titleTemplate: (titleChunk) => {
// If undefined or blank then we don't need the hyphen
return titleChunk ? `${titleChunk} - ${t('title')}` : t('title').toString();
},
meta: [
{ name: 'format-detection', content: 'telephone=no' },
{
name: 'description',
content: t('defaultDescription'),
},
{
name: 'keywords',
content:
'tchoukball, tchouk, tchouk-ball, sport, sport pour tous, fair-play, accessible, intense, tactique, prix thulin, Swiss Tchoukball, fédération, verband, federazione, federation, switzerland, suisse, schweiz, svizerra',
},
{ property: 'og:site_name', content: t('title') },
{
property: 'og:description',
content: (route.meta.description as string) || t('defaultDescription'),
},
{
property: 'og:type',
content: `website`,
},
{
property: 'og:url',
content: `${runtimeConfig.public.websiteBaseUrl}${route.path}`,
},
{
property: 'og:image',
content: `${runtimeConfig.public.websiteBaseUrl}/images/og-swiss-tchoukball.jpg`,
},
{
property: 'og:image:alt',
content: 'Logo of Swiss Tchoukball over a background featuring the net of a tchoukball frame.',
},
{
name: 'twitter:card',
content: 'summary',
},
{
name: 'twitter:site',
content: '@SwissTchoukball',
},
],
link: [
{ rel: 'apple-touch-icon', sizes: '180x180', href: '/apple-touch-icon.png' },
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
{ rel: 'icon', type: 'image/png', sizes: '32x32', href: '/favicon-32x32.png' },
{ rel: 'icon', type: 'image/png', sizes: '16x16', href: '/favicon-16x16.png' },
{ rel: 'manifest', href: '/site.webmanifest' },
{ rel: 'mask-icon', href: '/safari-pinned-tab.svg', color: '#ff0000' },
{
rel: 'alternate',
type: 'application/rss+xml',
hreflang: 'fr',
href: 'https://feeds.tchoukball.ch/news-fr.xml',
title: 'News Swiss Tchoukball en français',
},
{
rel: 'alternate',
type: 'application/rss+xml',
hreflang: 'de',
href: 'https://feeds.tchoukball.ch/news-de.xml',
title: 'Swiss Tchoukball News auf Deutsch',
},
],
};
});
</script>