Add SEO info
This commit is contained in:
@@ -48,7 +48,7 @@
|
|||||||
- [x] Pretty slugified urls
|
- [x] Pretty slugified urls
|
||||||
- [x] All static texts translated
|
- [x] All static texts translated
|
||||||
- [ ] Pretty
|
- [ ] Pretty
|
||||||
- [ ] SEO, Meta, Preview
|
- [x] SEO, Meta, Preview
|
||||||
- [ ] Deployment `.on.hs-bremen.de`??
|
- [ ] Deployment `.on.hs-bremen.de`??
|
||||||
|
|
||||||
```txt
|
```txt
|
||||||
|
|||||||
@@ -40,7 +40,25 @@ useHead({
|
|||||||
]
|
]
|
||||||
.filter((s) => s && s?.length > 0)
|
.filter((s) => s && s?.length > 0)
|
||||||
.join(' | ') || t('layouts.default_tile')
|
.join(' | ') || t('layouts.default_tile')
|
||||||
})
|
}),
|
||||||
|
meta: [
|
||||||
|
{
|
||||||
|
property: 'og:title',
|
||||||
|
content: hasKey(data.value, 'title')
|
||||||
|
? tKey(data.value!, 'title').value
|
||||||
|
: questSlug?.name
|
||||||
|
},
|
||||||
|
{
|
||||||
|
property: 'og:description',
|
||||||
|
content: hasKey(data.value, 'description')
|
||||||
|
? tKey(data.value!, 'description').value
|
||||||
|
: questSlug?.name
|
||||||
|
},
|
||||||
|
{
|
||||||
|
property: 'og:image',
|
||||||
|
content: data.value?.picture?.url
|
||||||
|
}
|
||||||
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
const answer = ref(data.value?.answer?.text);
|
const answer = ref(data.value?.answer?.text);
|
||||||
|
|||||||
@@ -20,7 +20,25 @@ const hideAnswers = ref(true);
|
|||||||
useHead({
|
useHead({
|
||||||
title: t('layouts.title', {
|
title: t('layouts.title', {
|
||||||
title: hasKey(data.value, 'name') ? tKey(data.value!, 'name').value : name
|
title: hasKey(data.value, 'name') ? tKey(data.value!, 'name').value : name
|
||||||
})
|
}),
|
||||||
|
meta: [
|
||||||
|
{
|
||||||
|
property: 'og:title',
|
||||||
|
content: hasKey(data.value, 'name')
|
||||||
|
? tKey(data.value!, 'name').value
|
||||||
|
: name
|
||||||
|
},
|
||||||
|
{
|
||||||
|
property: 'og:description',
|
||||||
|
content: hasKey(data.value, 'description')
|
||||||
|
? tKey(data.value!, 'description').value
|
||||||
|
: name
|
||||||
|
},
|
||||||
|
{
|
||||||
|
property: 'og:image',
|
||||||
|
content: data.value?.picture?.url
|
||||||
|
}
|
||||||
|
]
|
||||||
});
|
});
|
||||||
|
|
||||||
watch(loggedIn, () => refresh());
|
watch(loggedIn, () => refresh());
|
||||||
|
|||||||
Reference in New Issue
Block a user